📄 linearwindow.java
字号:
// Decompiled by Jad v1.5.7g. Copyright 2000 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/SiliconValley/Bridge/8617/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi
// Source File Name: LinearWindow.java
package dtw;
import timeseries.TimeSeries;
// Referenced classes of package dtw:
// SearchWindow
public class LinearWindow extends SearchWindow
{
private static final int defaultRadius = 0;
public LinearWindow(TimeSeries tsI, TimeSeries tsJ, int searchRadius)
{
super(tsI.size(), tsJ.size());
double ijRatio = (double)tsI.size() / (double)tsJ.size();
boolean isIlargest = tsI.size() >= tsJ.size();
for(int i = 0; i < tsI.size(); i++)
if(isIlargest)
{
int j = Math.min((int)Math.round((double)i / ijRatio), tsJ.size() - 1);
super.markVisited(i, j);
} else
{
int maxJ = (int)Math.round((double)(i + 1) / ijRatio) - 1;
int minJ = (int)Math.round((double)i / ijRatio);
super.markVisited(i, minJ);
super.markVisited(i, maxJ);
}
super.expandWindow(searchRadius);
}
public LinearWindow(TimeSeries tsI, TimeSeries tsJ)
{
this(tsI, tsJ, 0);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -