class_docstr: Abstract base class for time series clusterer.
  
  Parameters
  ----------
  n_clusters: int, defaults = None
      Number of clusters for model.
class_docstr_tok: ["Abstract","base","class","for","time","series","clusterer",".","Parameters","--","--","--","--","--","n_clusters",":","int",",","defaults","=","None","Number","of","clusters","for","model","."]
docstr: Fit time series clusterer to training data.
  
  Parameters
  ----------
  X : Training time series instances to cluster. np.ndarray (2d or 3d array of
  shape (n_instances, series_length) or shape (n_instances, n_dimensions,
  series_length)) or pd.DataFrame (where each column is a dimension, each cell
  is a pd.Series (any number of dimensions, equal or unequal length series)).
  Converted to type _tags["X_inner_mtype"]
  y: ignored, exists for API consistency reasons.
  
  Returns
  -------
  self:
      Fitted estimator.
docstr_tok: ["Fit","time","series","clusterer","to","training","data",".","Parameters","--","--","--","--","--","X",":","Training","time","series","instances","to","cluster",".","np.ndarray","(","2d","or","3d","array","of","shape","(","n_instances",",","series_length",")","or","shape","(","n_instances",",","n_dimensions",",","series_length",")",")","or","pd.DataFrame","(","where","each","column","is","a","dimension",",","each","cell","is","a","pd.Series","(","any","number","of","dimensions",",","equal","or","unequal","length","series",")",")",".","Converted","to","type","_tags","[","``","X_inner_mtype","''","]","y",":","ignored",",","exists","for","API","consistency","reasons",".","Returns","--","--","--","-","self",":","Fitted","estimator","."]
code: def fit(self, X: TimeSeriesInstances, y=None) -> BaseEstimator:
      """Fit time series clusterer to training data.
  
      Parameters
      ----------
      X : Training time series instances to cluster. np.ndarray (2d or 3d array of
      shape (n_instances, series_length) or shape (n_instances, n_dimensions,
      series_length)) or pd.DataFrame (where each column is a dimension, each cell
      is a pd.Series (any number of dimensions, equal or unequal length series)).
      Converted to type _tags["X_inner_mtype"]
      y: ignored, exists for API consistency reasons.
  
      Returns
      -------
      self:
          Fitted estimator.
      """
      # reset estimator at the start of fit
      self.reset()
  
      X = self._check_clusterer_input(X)
  
      multithread = self.get_tag("capability:multithreading")
      if multithread:
          try:
              self._threads_to_use = check_n_jobs(self.n_jobs)
          except NameError:
              raise AttributeError(
                  "self.n_jobs must be set if capability:multithreading is True"
              )
  
      start = int(round(time.time() * 1000))
      self._fit(X)
      self.fit_time_ = int(round(time.time() * 1000)) - start
      self._is_fitted = True
      return self
  
imports: import time
  from typing import Any, Union
  import numpy
  import pandas
  from sktime.base import BaseEstimator
  from sktime.datatypes import check_is_scitype, convert_to, scitype_to_mtype
  from sktime.utils.sklearn import is_sklearn_transformer
  from sktime.utils.validation import check_n_jobs
  from sktime.utils.validation._dependencies import _check_estimator_deps
label_desc: Use image node_id 3 for calling the BaseClusterer obj's underlying member method code with example usage: obj.fit(X, y) and returns: self