Skip to content

Core Compatibility Report: sympathetic-mosquito/v0ยค

๐ŸŸก bioimageio format validation
status valid-format
source https://hypha.aicell.io/bioimage-io/artifacts/sympathetic-mosquito/files/rdf.yaml?version=v0
id sympathetic-mosquito
format version model 0.4.10
bioimageio.spec 0.5.6.0
Location Details
โœ”๏ธ Successfully created `ModelDescr` instance.
โœ”๏ธ bioimageio.spec format validation model 0.4.10
โŒ weights.keras_hdf5 Reproduce test outputs from test inputs (keras_hdf5)
โŒ weights.keras_hdf5
Error when deserializing class 'Conv2D' using config={'name': 'conv2d', 'trainable': True, 'dtype': 'float32', 'filters': 64, 'kernel_size': [3, 3], 'strides': [1, 1], 'padding': 'same', 'data_format': 'channels_last', 'dilation_rate': [1, 1], 'activation': 'relu', 'use_bias': True, 'kernel_initializer': {'class_name': 'VarianceScaling', 'config': {'scale': 2.0, 'mode': 'fan_in', 'distribution': 'truncated_normal', 'seed': None, 'dtype': 'float32'}}, 'bias_initializer': {'class_name': 'Zeros', 'config': {'dtype': 'float32'}}, 'kernel_regularizer': None, 'bias_regularizer': None, 'activity_regularizer': None, 'kernel_constraint': None, 'bias_constraint': None}.

Exception encountered:  could not be deserialized properly. Please ensure that components that are Python object instances (layers, models, etc.) returned by `get_config()` are explicitly deserialized in the model's `from_config()` method.

config={'module': 'keras.initializers', 'class_name': 'VarianceScaling', 'config': {'scale': 2.0, 'mode': 'fan_in', 'distribution': 'truncated_normal', 'seed': None, 'dtype': 'float32'}, 'registered_name': None}.

Exception encountered: VarianceScaling.__init__() got an unexpected keyword argument 'dtype'
See Traceback 1.
weights.keras_hdf5
recommended conda environment (Reproduce test outputs from test inputs (keras_hdf5))
%YAML 1.2
---
channels:
  - conda-forge
  - nodefaults
dependencies:
  - bioimageio.core
  - pip
  - tensorflow ==2.17
weights.keras_hdf5
conda compare (Reproduce test outputs from test inputs (keras_hdf5))
Success. All the packages in the specification file are present in the environment with matching
version and build string.

Traceback 1








    
โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ Traceback (most recent call last) โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/saving/serialization_lib.py:733 in de โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   730 โ”‚   safe_mode_scope = SafeModeScope(safe_mode)                                             โ”‚
โ”‚   731 โ”‚   with custom_obj_scope, safe_mode_scope:                                                โ”‚
โ”‚   732 โ”‚   โ”‚   try:                                                                               โ”‚
โ”‚ โฑ 733 โ”‚   โ”‚   โ”‚   instance = cls.from_config(inner_config)                                       โ”‚
โ”‚   734 โ”‚   โ”‚   except TypeError as e:                                                             โ”‚
โ”‚   735 โ”‚   โ”‚   โ”‚   raise TypeError(                                                               โ”‚
โ”‚   736 โ”‚   โ”‚   โ”‚   โ”‚   f"{cls} could not be deserialized properly. Please"                        โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/initializers/initializer.py:81 in fro โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   78 โ”‚   โ”‚   Returns:                                                                            โ”‚
โ”‚   79 โ”‚   โ”‚   โ”‚   An `Initializer` instance.                                                      โ”‚
โ”‚   80 โ”‚   โ”‚   """                                                                                 โ”‚
โ”‚ โฑ 81 โ”‚   โ”‚   return cls(**config)                                                                โ”‚
โ”‚   82 โ”‚                                                                                           โ”‚
โ”‚   83 โ”‚   def clone(self):                                                                        โ”‚
โ”‚   84 โ”‚   โ”‚   return self.__class__.from_config(self.get_config())                                โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ
TypeError: VarianceScaling.__init__() got an unexpected keyword argument 'dtype'

During handling of the above exception, another exception occurred:

โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ Traceback (most recent call last) โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/ops/operation.py:317 in from_config   โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   314 โ”‚   โ”‚   โ”‚   โ”‚   policy = policy.name                                                       โ”‚
โ”‚   315 โ”‚   โ”‚   โ”‚   config["dtype"] = policy                                                       โ”‚
โ”‚   316 โ”‚   โ”‚   try:                                                                               โ”‚
โ”‚ โฑ 317 โ”‚   โ”‚   โ”‚   return cls(**config)                                                           โ”‚
โ”‚   318 โ”‚   โ”‚   except Exception as e:                                                             โ”‚
โ”‚   319 โ”‚   โ”‚   โ”‚   raise TypeError(                                                               โ”‚
โ”‚   320 โ”‚   โ”‚   โ”‚   โ”‚   f"Error when deserializing class '{cls.__name__}' using "                  โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/layers/convolutional/conv2d.py:118 in โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   115 โ”‚   โ”‚   bias_constraint=None,                                                              โ”‚
โ”‚   116 โ”‚   โ”‚   **kwargs,                                                                          โ”‚
โ”‚   117 โ”‚   ):                                                                                     โ”‚
โ”‚ โฑ 118 โ”‚   โ”‚   super().__init__(                                                                  โ”‚
โ”‚   119 โ”‚   โ”‚   โ”‚   rank=2,                                                                        โ”‚
โ”‚   120 โ”‚   โ”‚   โ”‚   filters=filters,                                                               โ”‚
โ”‚   121 โ”‚   โ”‚   โ”‚   kernel_size=kernel_size,                                                       โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/layers/convolutional/base_conv.py:126 โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   123 โ”‚   โ”‚   self.data_format = standardize_data_format(data_format)                            โ”‚
โ”‚   124 โ”‚   โ”‚   self.activation = activations.get(activation)                                      โ”‚
โ”‚   125 โ”‚   โ”‚   self.use_bias = use_bias                                                           โ”‚
โ”‚ โฑ 126 โ”‚   โ”‚   self.kernel_initializer = initializers.get(kernel_initializer)                     โ”‚
โ”‚   127 โ”‚   โ”‚   self.bias_initializer = initializers.get(bias_initializer)                         โ”‚
โ”‚   128 โ”‚   โ”‚   self.kernel_regularizer = regularizers.get(kernel_regularizer)                     โ”‚
โ”‚   129 โ”‚   โ”‚   self.bias_regularizer = regularizers.get(bias_regularizer)                         โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/initializers/__init__.py:133 in get   โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   130 โ”‚   if identifier is None:                                                                 โ”‚
โ”‚   131 โ”‚   โ”‚   return None                                                                        โ”‚
โ”‚   132 โ”‚   if isinstance(identifier, dict):                                                       โ”‚
โ”‚ โฑ 133 โ”‚   โ”‚   obj = deserialize(identifier)                                                      โ”‚
โ”‚   134 โ”‚   elif isinstance(identifier, str):                                                      โ”‚
โ”‚   135 โ”‚   โ”‚   config = {"class_name": str(identifier), "config": {}}                             โ”‚
โ”‚   136 โ”‚   โ”‚   obj = deserialize(config)                                                          โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/initializers/__init__.py:75 in deseri โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    72 @keras_export("keras.initializers.deserialize")                                            โ”‚
โ”‚    73 def deserialize(config, custom_objects=None):                                              โ”‚
โ”‚    74 โ”‚   """Returns a Keras initializer object via its configuration."""                        โ”‚
โ”‚ โฑ  75 โ”‚   return serialization_lib.deserialize_keras_object(                                     โ”‚
โ”‚    76 โ”‚   โ”‚   config,                                                                            โ”‚
โ”‚    77 โ”‚   โ”‚   module_objects=ALL_OBJECTS_DICT,                                                   โ”‚
โ”‚    78 โ”‚   โ”‚   custom_objects=custom_objects,                                                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/saving/serialization_lib.py:596 in de โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   593 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   ),                                                                     โ”‚
โ”‚   594 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   custom_objects=custom_objects,                                         โ”‚
โ”‚   595 โ”‚   โ”‚   โ”‚   โ”‚   )                                                                          โ”‚
โ”‚ โฑ 596 โ”‚   โ”‚   โ”‚   return deserialize_keras_object(                                               โ”‚
โ”‚   597 โ”‚   โ”‚   โ”‚   โ”‚   serialize_with_public_class(                                               โ”‚
โ”‚   598 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   module_objects[config], inner_config=inner_config                      โ”‚
โ”‚   599 โ”‚   โ”‚   โ”‚   โ”‚   ),                                                                         โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/saving/serialization_lib.py:735 in de โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   732 โ”‚   โ”‚   try:                                                                               โ”‚
โ”‚   733 โ”‚   โ”‚   โ”‚   instance = cls.from_config(inner_config)                                       โ”‚
โ”‚   734 โ”‚   โ”‚   except TypeError as e:                                                             โ”‚
โ”‚ โฑ 735 โ”‚   โ”‚   โ”‚   raise TypeError(                                                               โ”‚
โ”‚   736 โ”‚   โ”‚   โ”‚   โ”‚   f"{cls} could not be deserialized properly. Please"                        โ”‚
โ”‚   737 โ”‚   โ”‚   โ”‚   โ”‚   " ensure that components that are Python object"                           โ”‚
โ”‚   738 โ”‚   โ”‚   โ”‚   โ”‚   " instances (layers, models, etc.) returned by"                            โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ
TypeError: <class 'keras.src.initializers.random_initializers.VarianceScaling'> could not be deserialized properly. Please ensure that components that are Python object instances (layers, models, etc.) returned by `get_config()` are explicitly deserialized in the model's `from_config()` method.

config={'module': 'keras.initializers', 'class_name': 'VarianceScaling', 'config': {'scale': 2.0, 'mode': 'fan_in', 'distribution': 'truncated_normal', 'seed': None, 'dtype': 'float32'}, 'registered_name': None}.

Exception encountered: VarianceScaling.__init__() got an unexpected keyword argument 'dtype'

During handling of the above exception, another exception occurred:

โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ Traceback (most recent call last) โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ /home/runner/.local/lib/python3.12/site-packages/bioimageio/core/_resource_tests.py:784 in _test โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    781 โ”‚   โ”‚   test_input = get_test_input_sample(model)                                         โ”‚
โ”‚    782 โ”‚   โ”‚   expected = get_test_output_sample(model)                                          โ”‚
โ”‚    783 โ”‚   โ”‚                                                                                     โ”‚
โ”‚ โฑ  784 โ”‚   โ”‚   with create_prediction_pipeline(                                                  โ”‚
โ”‚    785 โ”‚   โ”‚   โ”‚   bioimageio_model=model, devices=devices, weight_format=weight_format          โ”‚
โ”‚    786 โ”‚   โ”‚   ) as prediction_pipeline:                                                         โ”‚
โ”‚    787 โ”‚   โ”‚   โ”‚   results = prediction_pipeline.predict_sample_without_blocking(test_input)     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/bioimageio/core/_prediction_pipeline.py:371 in  โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   368 โ”‚   โ”‚   โ”‚   f"deprecated create_prediction_pipeline kwargs: {set(deprecated_kwargs)}"      โ”‚
โ”‚   369 โ”‚   โ”‚   )                                                                                  โ”‚
โ”‚   370 โ”‚                                                                                          โ”‚
โ”‚ โฑ 371 โ”‚   model_adapter = model_adapter or create_model_adapter(                                 โ”‚
โ”‚   372 โ”‚   โ”‚   model_description=bioimageio_model,                                                โ”‚
โ”‚   373 โ”‚   โ”‚   devices=devices,                                                                   โ”‚
โ”‚   374 โ”‚   โ”‚   weight_format_priority_order=weights_format and (weights_format,),                 โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/bioimageio/core/backends/_model_adapter.py:169  โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   166 โ”‚   โ”‚   assert errors                                                                      โ”‚
โ”‚   167 โ”‚   โ”‚   if len(weight_format_priority_order) == 1:                                         โ”‚
โ”‚   168 โ”‚   โ”‚   โ”‚   assert len(errors) == 1                                                        โ”‚
โ”‚ โฑ 169 โ”‚   โ”‚   โ”‚   raise errors[0]                                                                โ”‚
โ”‚   170 โ”‚   โ”‚                                                                                      โ”‚
โ”‚   171 โ”‚   โ”‚   else:                                                                              โ”‚
โ”‚   172 โ”‚   โ”‚   โ”‚   msg = (                                                                        โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/bioimageio/core/backends/_model_adapter.py:158  โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   155 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   except Exception:                                                      โ”‚
โ”‚   156 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   from .tensorflow_backend import KerasModelAdapter                  โ”‚
โ”‚   157 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚                                                                          โ”‚
โ”‚ โฑ 158 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   return KerasModelAdapter(                                              โ”‚
โ”‚   159 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   model_description=model_description, devices=devices               โ”‚
โ”‚   160 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   )                                                                      โ”‚
โ”‚   161 โ”‚   โ”‚   โ”‚   โ”‚   except Exception as e:                                                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/bioimageio/core/backends/keras_backend.py:87 in โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    84 โ”‚   โ”‚   โ”‚   โ”‚   with temp_path.open("wb") as f:                                            โ”‚
โ”‚    85 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   shutil.copyfileobj(weight_reader, f)                                   โ”‚
โ”‚    86 โ”‚   โ”‚   โ”‚   โ”‚                                                                              โ”‚
โ”‚ โฑ  87 โ”‚   โ”‚   โ”‚   โ”‚   self._network = keras.models.load_model(temp_path)                         โ”‚
โ”‚    88 โ”‚   โ”‚                                                                                      โ”‚
โ”‚    89 โ”‚   โ”‚   self._output_axes = [                                                              โ”‚
โ”‚    90 โ”‚   โ”‚   โ”‚   tuple(a.id for a in get_axes_infos(out))                                       โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/saving/saving_api.py:196 in load_mode โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   193 โ”‚   โ”‚   โ”‚   safe_mode=safe_mode,                                                           โ”‚
โ”‚   194 โ”‚   โ”‚   )                                                                                  โ”‚
โ”‚   195 โ”‚   if str(filepath).endswith((".h5", ".hdf5")):                                           โ”‚
โ”‚ โฑ 196 โ”‚   โ”‚   return legacy_h5_format.load_model_from_hdf5(                                      โ”‚
โ”‚   197 โ”‚   โ”‚   โ”‚   filepath,                                                                      โ”‚
โ”‚   198 โ”‚   โ”‚   โ”‚   custom_objects=custom_objects,                                                 โ”‚
โ”‚   199 โ”‚   โ”‚   โ”‚   compile=compile,                                                               โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/legacy/saving/legacy_h5_format.py:137 โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   134 โ”‚   โ”‚   legacy_scope = saving_options.keras_option_scope(use_legacy_config=True)           โ”‚
โ”‚   135 โ”‚   โ”‚   safe_mode_scope = serialization_lib.SafeModeScope(safe_mode)                       โ”‚
โ”‚   136 โ”‚   โ”‚   with legacy_scope, safe_mode_scope:                                                โ”‚
โ”‚ โฑ 137 โ”‚   โ”‚   โ”‚   model = saving_utils.model_from_config(                                        โ”‚
โ”‚   138 โ”‚   โ”‚   โ”‚   โ”‚   model_config, custom_objects=custom_objects                                โ”‚
โ”‚   139 โ”‚   โ”‚   โ”‚   )                                                                              โ”‚
โ”‚   140                                                                                            โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/legacy/saving/saving_utils.py:83 in m โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    80 โ”‚   โ”‚   โ”‚   function_dict["config"]["closure"] = function_config[2]                        โ”‚
โ”‚    81 โ”‚   โ”‚   โ”‚   config["config"]["function"] = function_dict                                   โ”‚
โ”‚    82 โ”‚                                                                                          โ”‚
โ”‚ โฑ  83 โ”‚   return serialization.deserialize_keras_object(                                         โ”‚
โ”‚    84 โ”‚   โ”‚   config,                                                                            โ”‚
โ”‚    85 โ”‚   โ”‚   module_objects=MODULE_OBJECTS.ALL_OBJECTS,                                         โ”‚
โ”‚    86 โ”‚   โ”‚   custom_objects=custom_objects,                                                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/legacy/saving/serialization.py:488 in โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   485 โ”‚   โ”‚   โ”‚   custom_objects = custom_objects or {}                                          โ”‚
โ”‚   486 โ”‚   โ”‚   โ”‚                                                                                  โ”‚
โ”‚   487 โ”‚   โ”‚   โ”‚   if "custom_objects" in arg_spec.args:                                          โ”‚
โ”‚ โฑ 488 โ”‚   โ”‚   โ”‚   โ”‚   deserialized_obj = cls.from_config(                                        โ”‚
โ”‚   489 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   cls_config,                                                            โ”‚
โ”‚   490 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   custom_objects={                                                       โ”‚
โ”‚   491 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   **object_registration.GLOBAL_CUSTOM_OBJECTS,                       โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/models/model.py:694 in from_config    โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   691 โ”‚   โ”‚   โ”‚   # (but not Functional subclasses with a custom __init__)                       โ”‚
โ”‚   692 โ”‚   โ”‚   โ”‚   from keras.src.models.functional import functional_from_config                 โ”‚
โ”‚   693 โ”‚   โ”‚   โ”‚                                                                                  โ”‚
โ”‚ โฑ 694 โ”‚   โ”‚   โ”‚   return functional_from_config(                                                 โ”‚
โ”‚   695 โ”‚   โ”‚   โ”‚   โ”‚   cls, config, custom_objects=custom_objects                                 โ”‚
โ”‚   696 โ”‚   โ”‚   โ”‚   )                                                                              โ”‚
โ”‚   697                                                                                            โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/models/functional.py:558 in functiona โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   555 โ”‚                                                                                          โ”‚
โ”‚   556 โ”‚   # First, we create all layers and enqueue nodes to be processed                        โ”‚
โ”‚   557 โ”‚   for layer_data in functional_config["layers"]:                                         โ”‚
โ”‚ โฑ 558 โ”‚   โ”‚   process_layer(layer_data)                                                          โ”‚
โ”‚   559 โ”‚                                                                                          โ”‚
โ”‚   560 โ”‚   # Then we process nodes in order of layer depth.                                       โ”‚
โ”‚   561 โ”‚   # Nodes that cannot yet be processed (if the inbound node                              โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/models/functional.py:521 in process_l โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   518 โ”‚   โ”‚   if "module" not in layer_data:                                                     โ”‚
โ”‚   519 โ”‚   โ”‚   โ”‚   # Legacy format deserialization (no "module" key)                              โ”‚
โ”‚   520 โ”‚   โ”‚   โ”‚   # used for H5 and SavedModel formats                                           โ”‚
โ”‚ โฑ 521 โ”‚   โ”‚   โ”‚   layer = saving_utils.model_from_config(                                        โ”‚
โ”‚   522 โ”‚   โ”‚   โ”‚   โ”‚   layer_data, custom_objects=custom_objects                                  โ”‚
โ”‚   523 โ”‚   โ”‚   โ”‚   )                                                                              โ”‚
โ”‚   524 โ”‚   โ”‚   else:                                                                              โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/legacy/saving/saving_utils.py:83 in m โ”‚
โ”‚                                                                                                  โ”‚
โ”‚    80 โ”‚   โ”‚   โ”‚   function_dict["config"]["closure"] = function_config[2]                        โ”‚
โ”‚    81 โ”‚   โ”‚   โ”‚   config["config"]["function"] = function_dict                                   โ”‚
โ”‚    82 โ”‚                                                                                          โ”‚
โ”‚ โฑ  83 โ”‚   return serialization.deserialize_keras_object(                                         โ”‚
โ”‚    84 โ”‚   โ”‚   config,                                                                            โ”‚
โ”‚    85 โ”‚   โ”‚   module_objects=MODULE_OBJECTS.ALL_OBJECTS,                                         โ”‚
โ”‚    86 โ”‚   โ”‚   custom_objects=custom_objects,                                                     โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/legacy/saving/serialization.py:497 in โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   494 โ”‚   โ”‚   โ”‚   โ”‚   )                                                                          โ”‚
โ”‚   495 โ”‚   โ”‚   โ”‚   else:                                                                          โ”‚
โ”‚   496 โ”‚   โ”‚   โ”‚   โ”‚   with object_registration.CustomObjectScope(custom_objects):                โ”‚
โ”‚ โฑ 497 โ”‚   โ”‚   โ”‚   โ”‚   โ”‚   deserialized_obj = cls.from_config(cls_config)                         โ”‚
โ”‚   498 โ”‚   โ”‚   else:                                                                              โ”‚
โ”‚   499 โ”‚   โ”‚   โ”‚   # Then `cls` may be a function returning a class.                              โ”‚
โ”‚   500 โ”‚   โ”‚   โ”‚   # in this case by convention `config` holds                                    โ”‚
โ”‚                                                                                                  โ”‚
โ”‚ /home/runner/.local/lib/python3.12/site-packages/keras/src/ops/operation.py:319 in from_config   โ”‚
โ”‚                                                                                                  โ”‚
โ”‚   316 โ”‚   โ”‚   try:                                                                               โ”‚
โ”‚   317 โ”‚   โ”‚   โ”‚   return cls(**config)                                                           โ”‚
โ”‚   318 โ”‚   โ”‚   except Exception as e:                                                             โ”‚
โ”‚ โฑ 319 โ”‚   โ”‚   โ”‚   raise TypeError(                                                               โ”‚
โ”‚   320 โ”‚   โ”‚   โ”‚   โ”‚   f"Error when deserializing class '{cls.__name__}' using "                  โ”‚
โ”‚   321 โ”‚   โ”‚   โ”‚   โ”‚   f"config={config}.\n\nException encountered: {e}"                          โ”‚
โ”‚   322 โ”‚   โ”‚   โ”‚   )                                                                              โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ
TypeError: Error when deserializing class 'Conv2D' using config={'name': 'conv2d', 'trainable': True, 'dtype': 'float32', 'filters': 64, 'kernel_size': [3, 3], 'strides': [1, 1], 'padding': 'same', 'data_format': 'channels_last', 'dilation_rate': [1, 1], 'activation': 'relu', 'use_bias': True, 'kernel_initializer': {'class_name': 'VarianceScaling', 'config': {'scale': 2.0, 'mode': 'fan_in', 'distribution': 'truncated_normal', 'seed': None, 'dtype': 'float32'}}, 'bias_initializer': {'class_name': 'Zeros', 'config': {'dtype': 'float32'}}, 'kernel_regularizer': None, 'bias_regularizer': None, 'activity_regularizer': None, 'kernel_constraint': None, 'bias_constraint': None}.

Exception encountered: <class 'keras.src.initializers.random_initializers.VarianceScaling'> could not be deserialized properly. Please ensure that components that are Python object instances (layers, models, etc.) returned by `get_config()` are explicitly deserialized in the model's `from_config()` method.

config={'module': 'keras.initializers', 'class_name': 'VarianceScaling', 'config': {'scale': 2.0, 'mode': 'fan_in', 'distribution': 'truncated_normal', 'seed': None, 'dtype': 'float32'}, 'registered_name': None}.

Exception encountered: VarianceScaling.__init__() got an unexpected keyword argument 'dtype'