class_docstr: LazyLoader that handles routing to different Keras version.
class_docstr_tok: ["LazyLoader","that","handles","routing","to","different","Keras","version","."]
code: def __getattr__(self, item):
      if item in ("_tfll_mode", "_tfll_initialized", "_tfll_name"):
          return super(types.ModuleType, self).__getattribute__(item)
      if not self._tfll_initialized:
          self._initialize()
      if self._tfll_keras_version == "keras_3":
          if (
              self._tfll_mode == "v1"
              and not self._tfll_submodule
              and item.startswith("compat.v1.")
          ):
              raise AttributeError(
                  "`tf.compat.v1.keras` is not available with Keras 3. Keras 3 has "
                  "no support for TF 1 APIs. You can install the `tf_keras` package "
                  "as an alternative, and set the environment variable "
                  "`TF_USE_LEGACY_KERAS=True` to configure TensorFlow to route "
                  "`tf.compat.v1.keras` to `tf_keras`."
              )
          elif (
              self._tfll_mode == "v2"
              and not self._tfll_submodule
              and item.startswith("compat.v2.")
          ):
              raise AttributeError(
                  "`tf.compat.v2.keras` is not available with Keras 3. Just use "
                  "`import keras` instead."
              )
          elif self._tfll_submodule and self._tfll_submodule.startswith(
              "__internal__.legacy."
          ):
              raise AttributeError(
                  f"`{item}` is not available with Keras 3."
              )
      module = self._load()
      return getattr(module, item)
  
imports: import importlib
  import os
  import types
  from tensorflow.python.platform import tf_logging
label_desc: Use image node_id 3 for calling the KerasLazyLoader obj's underlying member method code with example usage: obj.__getattr__(item) and returns: getattr, super