class_docstr: Remove seasonal components from a time series.
  
  Applies `statsmodels.tsa.seasonal.seasonal_compose` and removes the `seasonal`
  component in `transform`. Adds seasonal component back again in `inverse_transform`.
  Seasonality removal can be additive or multiplicative.
  
  `fit` computes :term:`seasonal components <Seasonality>` and
  stores them in `seasonal_` attribute.
  
  `transform` aligns seasonal components stored in `seasonal_` with
  the time index of the passed :term:`series <Time series>` and then
  subtracts them ("additive" model) from the passed :term:`series <Time series>`
  or divides the passed series by them ("multiplicative" model).
  
  Parameters
  ----------
  sp : int, default=1
      Seasonal periodicity.
  model : {"additive", "multiplicative"}, default="additive"
      Model to use for estimating seasonal component.
  
  Attributes
  ----------
  seasonal_ : array of length sp
      Seasonal components computed in seasonal decomposition.
  
  See Also
  --------
  ConditionalDeseasonalizer
  
  Notes
  -----
  For further explanation on seasonal components and additive vs.
  multiplicative models see
  `Forecasting: Principles and Practice <https://otexts.com/fpp3/components.html>`_.
  Seasonal decomposition is computed using `statsmodels
  <https://www.statsmodels.org/stable/generated/statsmodels.tsa.seasonal.seasonal_decompose.html>`_.
  
  Examples
  --------
  >>> from sktime.transformations.series.detrend import Deseasonalizer
  >>> from sktime.datasets import load_airline
  >>> y = load_airline()  # doctest: +SKIP
  >>> transformer = Deseasonalizer()  # doctest: +SKIP
  >>> y_hat = transformer.fit_transform(y)  # doctest: +SKIP
class_docstr_tok: ["Remove","seasonal","components","from","a","time","series",".","Applies","`","statsmodels.tsa.seasonal.seasonal_compose","`","and","removes","the","`","seasonal","`","component","in","`","transform","`",".","Adds","seasonal","component","back","again","in","`","inverse_transform","`",".","Seasonality","removal","can","be","additive","or","multiplicative",".","`","fit","`","computes",":","term",":","`","seasonal","components","<","Seasonality",">","`","and","stores","them","in","`","seasonal_","`","attribute",".","`","transform","`","aligns","seasonal","components","stored","in","`","seasonal_","`","with","the","time","index","of","the","passed",":","term",":","`","series","<","Time","series",">","`","and","then","subtracts","them","(","``","additive","''","model",")","from","the","passed",":","term",":","`","series","<","Time","series",">","`","or","divides","the","passed","series","by","them","(","``","multiplicative","''","model",")",".","Parameters","--","--","--","--","--","sp",":","int",",","default=1","Seasonal","periodicity",".","model",":","{","``","additive","''",",","``","multiplicative","''","}",",","default=","''","additive","''","Model","to","use","for","estimating","seasonal","component",".","Attributes","--","--","--","--","--","seasonal_",":","array","of","length","sp","Seasonal","components","computed","in","seasonal","decomposition",".","See","Also","--","--","--","--","ConditionalDeseasonalizer","Notes","--","--","-","For","further","explanation","on","seasonal","components","and","additive","vs.","multiplicative","models","see","`","Forecasting",":","Principles","and","Practice","<","https",":","\/\/otexts.com\/fpp3\/components.html",">","`","_",".","Seasonal","decomposition","is","computed","using","`","statsmodels","<","https",":","\/\/www.statsmodels.org\/stable\/generated\/statsmodels.tsa.seasonal.seasonal_decompose.html",">","`","_",".","Examples","--","--","--","--",">",">",">","from","sktime.transformations.series.detrend","import","Deseasonalizer",">",">",">","from","sktime.datasets","import","load_airline",">",">",">","y","=","load_airline","(",")","#","doctest",":","+SKIP",">",">",">","transformer","=","Deseasonalizer","(",")","#","doctest",":","+SKIP",">",">",">","y_hat","=","transformer.fit_transform","(","y",")","#","doctest",":","+SKIP"]
docstr: Logic used by `inverse_transform` to reverse transformation on `X`.
  
  Parameters
  ----------
  X : pd.Series or pd.DataFrame
      Data to be inverse transformed
  y : ignored argument for interface compatibility
      Additional data, e.g., labels for transformation
  
  Returns
  -------
  Xt : pd.Series or pd.DataFrame, same type as X
      inverse transformed version of X
docstr_tok: ["Logic","used","by","`","inverse_transform","`","to","reverse","transformation","on","`","X","`",".","Parameters","--","--","--","--","--","X",":","pd.Series","or","pd.DataFrame","Data","to","be","inverse","transformed","y",":","ignored","argument","for","interface","compatibility","Additional","data",",","e.g.",",","labels","for","transformation","Returns","--","--","--","-","Xt",":","pd.Series","or","pd.DataFrame",",","same","type","as","X","inverse","transformed","version","of","X"]
code: def _inverse_transform(self, X, y=None):
      """Logic used by `inverse_transform` to reverse transformation on `X`.
  
      Parameters
      ----------
      X : pd.Series or pd.DataFrame
          Data to be inverse transformed
      y : ignored argument for interface compatibility
          Additional data, e.g., labels for transformation
  
      Returns
      -------
      Xt : pd.Series or pd.DataFrame, same type as X
          inverse transformed version of X
      """
      seasonal = self._align_seasonal(X)
      Xt = self._private_inverse_transform(X, seasonal)
      return Xt
  
imports: import numpy
  import pandas
  from sktime.transformations.base import BaseTransformer
  from sktime.utils.datetime import _get_duration, _get_freq
  from sktime.utils.seasonality import autocorrelation_seasonality_test
  from sktime.utils.validation.forecasting import check_sp
label_desc: Use image node_id 7 for calling the Deseasonalizer obj's underlying member method code with example usage: obj._inverse_transform(X, y) and returns: Xt