@Override
  public void beforeStart(UDFParameters parameters, UDTFConfigurations configurations)
      throws Exception {
    configurations
        .setAccessStrategy(new SlidingSizeWindowAccessStrategy(Integer.MAX_VALUE))
        .setOutputDataType(Type.DOUBLE);
  }
This function calculates DTW distance between two input series.
library-udf/src/main/java/org/apache/iotdb/library/dmatch/UDAFDtw.java