class_docstr: Arsenal ensemble.
  
  Overview: an ensemble of ROCKET transformers using RidgeClassifierCV base
  classifier. Weights each classifier using the accuracy from the ridge
  cross-validation. Allows for generation of probability estimates at the
  expense of scalability compared to RocketClassifier.
  
  Parameters
  ----------
  num_kernels : int, default=2,000
      Number of kernels for each ROCKET transform.
  n_estimators : int, default=25
      Number of estimators to build for the ensemble.
  rocket_transform : str, default="rocket"
      The type of Rocket transformer to use.
      Valid inputs = ["rocket","minirocket","multirocket"]
  max_dilations_per_kernel : int, default=32
      MiniRocket and MultiRocket only. The maximum number of dilations per kernel.
  n_features_per_kernel : int, default=4
      MultiRocket only. The number of features per kernel.
  time_limit_in_minutes : int, default=0
      Time contract to limit build time in minutes, overriding n_estimators.
      Default of 0 means n_estimators is used.
  contract_max_n_estimators : int, default=100
      Max number of estimators when time_limit_in_minutes is set.
  save_transformed_data : bool, default=False
      Save the data transformed in fit for use in _get_train_probs.
  n_jobs : int, default=1
      The number of jobs to run in parallel for both `fit` and `predict`.
      ``-1`` means using all processors.
  random_state : int or None, default=None
      Seed for random number generation.
  
  Attributes
  ----------
  n_classes : int
      The number of classes.
  n_instances_ : int
      The number of train cases.
  n_dims_ : int
      The number of dimensions per case.
  series_length_ : int
      The length of each series.
  classes_ : list
      The classes labels.
  estimators_ : list of shape (n_estimators) of BaseEstimator
      The collections of estimators trained in fit.
  weights_ : list of shape (n_estimators) of float
      Weight of each estimator in the ensemble.
  transformed_data_ : list of shape (n_estimators) of ndarray with shape
  (n_instances,total_intervals * att_subsample_size)
      The transformed dataset for all classifiers. Only saved when
      save_transformed_data is true.
  
  See Also
  --------
  RocketClassifier
  
  Notes
  -----
  For the Java version, see
  `TSML <https://github.com/uea-machine-learning/tsml/blob/master/src/main/java
  /tsml/classifiers/kernel_based/Arsenal.java>`_.
  
  References
  ----------
  .. [1] Middlehurst, Matthew, James Large, Michael Flynn, Jason Lines, Aaron Bostrom,
     and Anthony Bagnall. "HIVE-COTE 2.0: a new meta ensemble for time series
     classification." arXiv preprint arXiv:2104.07551 (2021).
  
  Examples
  --------
  >>> from sktime.classification.kernel_based import Arsenal
  >>> from sktime.datasets import load_unit_test
  >>> X_train, y_train = load_unit_test(split="train", return_X_y=True)
  >>> X_test, y_test =load_unit_test(split="test", return_X_y=True) # doctest: +SKIP
  >>> clf = Arsenal(num_kernels=100, n_estimators=5) # doctest: +SKIP
  >>> clf.fit(X_train, y_train) # doctest: +SKIP
  Arsenal(...)
  >>> y_pred = clf.predict(X_test) # doctest: +SKIP
docstr: Predicts labels for sequences in X.
  
  Parameters
  ----------
  X : 3D np.array of shape = [n_instances, n_dimensions, series_length]
      The data to make predictions for.
  
  Returns
  -------
  y : array-like, shape = [n_instances]
      Predicted class labels.
docstr_tok: ["Predicts","labels","for","sequences","in","X.","Parameters","--","--","--","--","--","X",":","3D","np.array","of","shape","=","[","n_instances",",","n_dimensions",",","series_length","]","The","data","to","make","predictions","for",".","Returns","--","--","--","-","y",":","array-like",",","shape","=","[","n_instances","]","Predicted","class","labels","."]
code: def _predict(self, X) -> np.ndarray:
      """Predicts labels for sequences in X.
  
      Parameters
      ----------
      X : 3D np.array of shape = [n_instances, n_dimensions, series_length]
          The data to make predictions for.
  
      Returns
      -------
      y : array-like, shape = [n_instances]
          Predicted class labels.
      """
      rng = check_random_state(self.random_state)
      return np.array(
          [
              self.classes_[
                  int(rng.choice(np.flatnonzero(prob == prob.max())))
              ]
              for prob in self._predict_proba(X)
          ]
      )
  
imports: import time
  import numpy
  from joblib import Parallel, delayed
  from sklearn.linear_model import RidgeClassifierCV
  from sklearn.pipeline import make_pipeline
  from sklearn.preprocessing import StandardScaler
  from sklearn.utils import check_random_state
  from sktime.base._base import _clone_estimator
  from sktime.classification.base import BaseClassifier
  from sktime.transformations.panel.rocket import MiniRocket, MiniRocketMultivariate, MultiRocket, MultiRocketMultivariate, Rocket
  from sktime.utils.validation.panel import check_X_y
label_desc: Use image node_id 3 for calling the Arsenal obj's underlying member method code with example usage: obj._predict(X) and returns: np