class_docstr: Implementation of a Graphpipeline.
  
  This class is a generalized graph pipeline. Generalized means that it can
  contain forecasters, classifiers, etc. The graph pipeline mean that the structure
  is not linear. I.e., the each element of the pipeline can be the input of multiple
  other steps and not only one successors.
  
  `fit(y, X, *args)` - changes state by running `fit` on all sktime estimators and
      transformers in the pipeline. Note that depending on the sktime estimators and
      transformers that are added to the pipeline, different keywords are required.
      E.g., if a forecaster is part of the pipeline, a forecast horizon (fh) should be
      provided.
  `predict(X, *args)` - Results in calling predict on the estimators in the pipeline
      and transform or the specified method on the other skobjects in the pipeline.
      Depending on the skobject added to the pipeline, you might need to pass
      additional parameters to predict.
  `predict_interval(X, fh)`, `predict_quantiles(X, fh)` - as `predict(X, fh)`,
      with `predict_interval` or `predict_quantiles` substituted for `predict`.
  `predict_var`, `predict_proba` - are currently not supported
  `get_params`, `set_params` uses `sklearn` compatible nesting interface
  `add_step(skobject, name, edges, method, **kwargs)` - adds a skobject to the
      pipeline and setting the name as identifier and the steps specified with
      edges as input steps (predecessors). Thereby the method that should be
      called can be overridden using the method kwarg. Further provided kwargs
      are directly provided to the skobject if it is called.
  
  Parameters
  ----------
  param steps : A list of dicts that specify the steps of the pipeline. Further
      steps can be added by using add_step method.
      The dict requires the following keys:
          * skobject: `sktime` object, the skobject that should be added to the
               pipeline
          * name: str, the name of the step that is created
          * edges: dict, a dict with string keys to string values. Identifying the
               predcessors.  The keys of the edges dict specify to which argument
               of fit/predict/.. the output of the predecessors (the value of the
               dict specifies the predecessors name) should be passed.
          * method: str, an optional argument allowing to determine the method that
              should be executed when the pipeline calls the provided skobject.
              If not specified, the pipeline selects the method based on the method
              that is called on the pipeline (e.g., predict, transform, ..)
          * kwargs: additional kwargs are parameters that are provided to the
              skobject if fit/predict/.. is called.
  
  Attributes
  ----------
  attribute id_to_true_id : a dict with integer keys and values,
      mapping the python object id to skobject ids.
  attribute id_to_obj : a dict with integer keys and weak references of
      skobjects as values. The values are the weak references of the skobjects
      provided to the `add_step` method. We store the weak references to
      avoid that the id of the object is reassigned if the user deletes all it
      references to the object.
  attribute model_dict : a dict with integer keys and skobject values.
      This is a mapping of the id of the skobjects provided to `add_step`
      to the cloned skobject.
  attribute counter : integer, counts the number of steps in the pipeline.
  attribute steps : a dict with string keys and step object values.
      The key is the name that is specified if a skobject is added to the pipeline.
  attribute kwargs : a dict with str keys and object values. Stores all kwargs
      that are specified and might be passed to skobjects in the pipeline.
  
  Examples
  --------
  >>> from sktime.classification.distance_based import KNeighborsTimeSeriesClassifier
  >>> from sktime.datasets import load_arrow_head, load_longley
  >>> from sktime.split import temporal_train_test_split
  >>> from sktime.forecasting.naive import NaiveForecaster
  >>> from sktime.pipeline import Pipeline
  >>> from sktime.transformations.compose import Id
  >>> from sktime.transformations.series.boxcox import BoxCoxTransformer
  >>> from sktime.transformations.series.exponent import ExponentTransformer
  
      Example 1: Simple sequential pipeline of transformers using the generalized
      non-sequential pipeline implementation
  >>> y, X = load_longley()
  >>> general_pipeline = Pipeline()
  >>> for step in [
  ...     {"skobject": ExponentTransformer(), "name": "exp", "edges": {"X": "X"}},
  ...     {"skobject": BoxCoxTransformer(), "name": "box", "edges": {"X": "exp"}},
  ...     ]:
  ...     general_pipeline = general_pipeline.add_step(**step)
  >>> general_pipeline.fit(X=X) # doctest: +SKIP
  >>> result_general = general_pipeline.transform(X) # doctest: +SKIP
  
      Example 2: Classification sequential pipeline using the generalized
       non-sequential pipeline implementation
  >>> X, y = load_arrow_head(split="train", return_X_y=True)
  >>> general_pipeline = Pipeline()
  >>> for step in [
  ...     {"skobject": ExponentTransformer(), "name": "exp", "edges": {"X": "X"}},
  ...     {"skobject": KNeighborsTimeSeriesClassifier(),
  ...      "name": "knnclassifier",
  ...      "edges": {"X": "exp", "y": "y"}}]:
  ...     general_pipeline = general_pipeline.add_step(**step)
  >>> general_pipeline.fit(X=X, y=y) # doctest: +SKIP
  >>> result_general = general_pipeline.predict(X) # doctest: +SKIP
  
      Example 3: Forecasting pipeline with exogenous features using the
      generalized non-sequential pipeline implementation
  >>> y, X = load_longley()
  >>> y_train, y_test, X_train, X_test = temporal_train_test_split(y, X)
  >>> general_pipeline = Pipeline()
  >>> for step in [
  ...     {"skobject": ExponentTransformer(), "name": "exp", "edges": {"X": "X"}},
  ...     {"skobject": NaiveForecaster(),
  ...      "name": "SARIMAX",
  ...      "edges": {"X": "exp", "y": "y"}}]:
  ...     general_pipeline = general_pipeline.add_step(**step)
  >>> general_pipeline.fit(y=y_train, X=X_train, fh=[1, 2, 3, 4]) # doctest: +SKIP
  >>> result_general = general_pipeline.predict(X=X_test) # doctest: +SKIP
  
  **Acknowledgements**
  This graphical pipeline is inspired by pyWATTS that is developed by the Institute
  for Automation and Applied Informatics (IAI) at Karlsruhe Institute of Technology.
  The implementation is supported by IAI and the author benHeid is funded by
  HelmholtzAI.
  Furthermore, we also want to credit @ViktorKaz for his independent pipeline design
  that is similar to this one.
  
  References
  ----------
  .. [1]  @article{heidrich2021pywatts,
    title={pyWATTS: Python workflow automation tool for time series},
    author={Heidrich, Benedikt and Bartschat, Andreas and Turowski, Marian and
            Neumann, Oliver and Phipps, Kaleb and Meisenbacher, Stefan and
            Schmieder, Kai and Ludwig, Nicole and Mikut, Ralf and Hagenmeyer, Veit},
    journal={arXiv preprint arXiv:2106.10157},
    year={2021}
  }
code: def _initiate_call(self, X, y, kwargs):
      if not self._assembled:
          self._assemble_steps()
      for step in self.assembled_steps.values():
          step.reset()
      self.assembled_steps["X"].buffer = X
      self.assembled_steps["y"].buffer = y
      self.kwargs.update(kwargs)
  
imports: import warnings
  from copy import copy, deepcopy
  from sktime.base import BaseEstimator
  from sktime.pipeline.step import Step
  from sktime.transformations.series.subset import ColumnSelect
label_desc: Use image node_id 16 for calling the Pipeline obj's underlying member method code with example usage: obj._initiate_call(X, y, kwargs) without return types