class_docstr: Dynamic Time Warping (DTW) Alignment.
  
  Attributes
  ----------
  n
      The length of `series1`
  m
      The length of `series2`
  series1
      A `TimeSeries` to align with `series2`.
  series2
      A `TimeSeries` to align with `series1`.
  cost
      The `CostMatrix` for DTW.
class_docstr_tok: ["Dynamic","Time","Warping","(","DTW",")","Alignment",".","Attributes","--","--","--","--","--","n","The","length","of","`","series1","`","m","The","length","of","`","series2","`","series1","A","`","TimeSeries","`","to","align","with","`","series2","`",".","series2","A","`","TimeSeries","`","to","align","with","`","series1","`",".","cost","The","`","CostMatrix","`","for","DTW","."]
code: def __init__(
      self, series1: TimeSeries, series2: TimeSeries, cost: CostMatrix
  ):
      self.n = len(series1)
      self.m = len(series2)
      self.series1 = series1
      self.series2 = series2
      self.cost = cost
  
imports: import copy
  from typing import Callable, Optional, Union
  import numpy
  import pandas
  import xarray
  from darts import TimeSeries
  from darts.logging import get_logger, raise_if, raise_if_not
  from darts.timeseries import DIMS
  from .cost_matrix import CostMatrix
  from .window import CRWindow, NoWindow, Window
label_desc: Use image node_id 1 to create a new DTWAlignment object  with example: obj = DTWAlignment(series1, series2, cost)