class_docstr: Abstract base class for deep learning time series classifiers.
  
  The base classifier provides a deep learning default method for
  _predict and _predict_proba, and provides a new abstract method for building a
  model.
  
  Parameters
  ----------
  batch_size : int, default = 40
      training batch size for the model
  
  Attributes
  ----------
  self.model_ - the fitted DL model
docstr: Get Dict config that will be used when a serialization method is called.
  
  Returns
  -------
  copy : dict, the config to be serialized
docstr_tok: ["Get","Dict","config","that","will","be","used","when","a","serialization","method","is","called",".","Returns","--","--","--","-","copy",":","dict",",","the","config","to","be","serialized"]
code: def __getstate__(self):
      """Get Dict config that will be used when a serialization method is called.
  
      Returns
      -------
      copy : dict, the config to be serialized
      """
      from tensorflow.keras.optimizers import Optimizer, serialize
  
      copy = self.__dict__.copy()
  
      # Either optimizer might not exist at all(-1),
      # or it does and takes a value(including None)
      optimizer_attr = copy.get("optimizer", -1)
      if not isinstance(optimizer_attr, str):
          if optimizer_attr is None:
              # if it is None, then save it as 0, so it can be
              # later correctly restored as None
              copy["optimizer"] = 0
          elif optimizer_attr == -1:
              # if an `optimizer` parameter doesn't exist at all
              # save it as -1
              copy["optimizer"] = -1
          elif isinstance(optimizer_attr, Optimizer):
              copy["optimizer"] = serialize(optimizer_attr)
          else:
              raise ValueError(
                  f"`optimizer` of type {type(optimizer_attr)} cannot be "
                  "serialized, it should either be absent/None/str/"
                  "tf.keras.optimizers.Optimizer object"
              )
      else:
          # if it was a string, don't touch since already serializable
          pass
  
      check_before_deletion = ["model_", "history", "optimizer_"]
      for attribute in check_before_deletion:
          if copy.get(attribute) is not None:
              del copy[attribute]
      return copy
  
imports: from abc import ABC, abstractmethod
  import numpy
  from sklearn.preprocessing import LabelEncoder, OneHotEncoder
  from sklearn.utils import check_random_state
  from sktime.base._base import SERIALIZATION_FORMATS
  from sktime.classification.base import BaseClassifier
  from sktime.utils.validation._dependencies import _check_soft_dependencies
label_desc: Use image node_id 7 for calling the BaseDeepClassifier obj's underlying member method code with example usage: obj.__getstate__() and returns: copy