class_docstr: Transformer base class.
class_docstr_tok: ["Transformer","base","class","."]
docstr: Transform X and return a transformed version.
  
  private _transform containing the core logic, called from transform
  
  Parameters
  ----------
  X : Series or Panel of mtype X_inner_mtype
      if X_inner_mtype is list, _transform must support all types in it
      Data to be transformed
  y : Series or Panel, default=None
      Additional data, e.g., labels for transformation
  
  Returns
  -------
  transformed version of X
  type depends on type of X and scitype:transform-output tag:
      |          | `transform`  |                        |
      |   `X`    |  `-output`   |     type of return     |
      |----------|--------------|------------------------|
      | `Series` | `Primitives` | `pd.DataFrame` (1-row) |
      | `Panel`  | `Primitives` | `pd.DataFrame`         |
      | `Series` | `Series`     | `Series`               |
      | `Panel`  | `Series`     | `Panel`                |
      | `Series` | `Panel`      | `Panel`                |
  instances in return correspond to instances in `X`
  combinations not in the table are currently not supported
  
  See extension_templates/transformer.py for implementation details.
code: def _transform(self, X, y=None):
      """Transform X and return a transformed version.
  
      private _transform containing the core logic, called from transform
  
      Parameters
      ----------
      X : Series or Panel of mtype X_inner_mtype
          if X_inner_mtype is list, _transform must support all types in it
          Data to be transformed
      y : Series or Panel, default=None
          Additional data, e.g., labels for transformation
  
      Returns
      -------
      transformed version of X
      type depends on type of X and scitype:transform-output tag:
          |          | `transform`  |                        |
          |   `X`    |  `-output`   |     type of return     |
          |----------|--------------|------------------------|
          | `Series` | `Primitives` | `pd.DataFrame` (1-row) |
          | `Panel`  | `Primitives` | `pd.DataFrame`         |
          | `Series` | `Series`     | `Series`               |
          | `Panel`  | `Series`     | `Panel`                |
          | `Series` | `Panel`      | `Panel`                |
      instances in return correspond to instances in `X`
      combinations not in the table are currently not supported
  
      See extension_templates/transformer.py for implementation details.
      """
      raise NotImplementedError("abstract method")
  
imports: from itertools import product
  from typing import Union
  import numpy
  import pandas
  from sktime.base import BaseEstimator
  from sktime.datatypes import VectorizedDF, check_is_error_msg, check_is_mtype, check_is_scitype, convert, convert_to, mtype_to_scitype, update_data
  from sktime.datatypes._series_as_panel import convert_to_scitype
  from sktime.utils.sklearn import is_sklearn_classifier, is_sklearn_clusterer, is_sklearn_regressor, is_sklearn_transformer
  from sktime.utils.validation._dependencies import _check_estimator_deps
label_desc: Use image node_id 21 for calling the BaseTransformer obj's underlying member method code with example usage: obj._transform(X, y) without return types