docstr: Creates an optimizer from its config.
  
  This method is the reverse of `get_config`, capable of instantiating the
  same optimizer from the config dictionary.
  
  Args:
      config: A Python dictionary, typically the output of get_config.
      custom_objects: A Python dictionary mapping names to additional
        user-defined Python objects needed to recreate this optimizer.
  
  Returns:
      An optimizer instance.
docstr_tok: ["Creates","an","optimizer","from","its","config",".","This","method","is","the","reverse","of","`","get_config","`",",","capable","of","instantiating","the","same","optimizer","from","the","config","dictionary",".","Args",":","config",":","A","Python","dictionary",",","typically","the","output","of","get_config",".","custom_objects",":","A","Python","dictionary","mapping","names","to","additional","user-defined","Python","objects","needed","to","recreate","this","optimizer",".","Returns",":","An","optimizer","instance","."]
code: def from_config(cls, config, custom_objects=None):
      """Creates an optimizer from its config.
  
      This method is the reverse of `get_config`, capable of instantiating the
      same optimizer from the config dictionary.
  
      Args:
          config: A Python dictionary, typically the output of get_config.
          custom_objects: A Python dictionary mapping names to additional
            user-defined Python objects needed to recreate this optimizer.
  
      Returns:
          An optimizer instance.
      """
      if "learning_rate" in config:
          if isinstance(config["learning_rate"], dict):
              config[
                  "learning_rate"
              ] = serialization_lib.deserialize_keras_object(
                  config["learning_rate"], custom_objects=custom_objects
              )
      return cls(**config)
  
imports: import re
  import warnings
  import numpy
  from keras import backend
  from keras import initializers
  from keras import ops
  from keras.optimizers.schedules import learning_rate_schedule
  from keras.saving import serialization_lib
  from keras.utils import tracking
  from keras.utils.naming import auto_name
label_desc: Use image node_id 38 for calling the BaseOptimizer obj's underlying member method code with example usage: obj.from_config(cls, config, custom_objects) and returns: cls