transliteration / config.json
kavyamanohar's picture
Save model using Keras.
f4562d1 verified
{"module": "keras.src.models.functional", "class_name": "Functional", "config": {"name": "functional_1", "trainable": true, "layers": [{"module": "keras.layers", "class_name": "InputLayer", "config": {"batch_shape": [null, 80], "dtype": "float32", "sparse": false, "name": "encoder_input"}, "registered_name": null, "name": "encoder_input", "inbound_nodes": []}, {"module": "keras.layers", "class_name": "Embedding", "config": {"name": "encoder_embedding", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "input_dim": 28, "output_dim": 64, "embeddings_initializer": {"module": "keras.initializers", "class_name": "RandomUniform", "config": {"minval": -0.05, "maxval": 0.05, "seed": null}, "registered_name": null}, "embeddings_regularizer": null, "activity_regularizer": null, "embeddings_constraint": null, "mask_zero": false}, "registered_name": null, "build_config": {"input_shape": [null, 80]}, "name": "encoder_embedding", "inbound_nodes": [{"args": [{"class_name": "__keras_tensor__", "config": {"shape": [null, 80], "dtype": "float32", "keras_history": ["encoder_input", 0, 0]}}], "kwargs": {}}]}, {"module": "keras.layers", "class_name": "Bidirectional", "config": {"name": "bidirectional_1", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "merge_mode": "concat", "layer": {"module": "keras.layers", "class_name": "LSTM", "config": {"name": "forward_encoder_lstm", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "return_sequences": true, "return_state": false, "go_backwards": false, "stateful": false, "unroll": false, "zero_output_for_mask": true, "units": 128, "activation": "tanh", "recurrent_activation": "sigmoid", "use_bias": true, "kernel_initializer": {"module": "keras.initializers", "class_name": "GlorotUniform", "config": {"seed": null}, "registered_name": null, "shared_object_id": 133979586957888}, "recurrent_initializer": {"module": "keras.initializers", "class_name": "OrthogonalInitializer", "config": {"gain": 1.0, "seed": null}, "registered_name": null, "shared_object_id": 133979586957792}, "bias_initializer": {"module": "keras.initializers", "class_name": "Zeros", "config": {}, "registered_name": null, "shared_object_id": 133979586957696}, "unit_forget_bias": true, "kernel_regularizer": null, "recurrent_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_constraint": null, "recurrent_constraint": null, "bias_constraint": null, "dropout": 0.0, "recurrent_dropout": 0.0, "seed": null}, "registered_name": null, "build_config": {"input_shape": [null, 80, 64]}}, "backward_layer": {"module": "keras.layers", "class_name": "LSTM", "config": {"name": "backward_encoder_lstm", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "return_sequences": true, "return_state": false, "go_backwards": true, "stateful": false, "unroll": false, "zero_output_for_mask": true, "units": 128, "activation": "tanh", "recurrent_activation": "sigmoid", "use_bias": true, "kernel_initializer": {"module": "keras.initializers", "class_name": "GlorotUniform", "config": {"seed": null}, "registered_name": null, "shared_object_id": 133979648426480}, "recurrent_initializer": {"module": "keras.initializers", "class_name": "OrthogonalInitializer", "config": {"gain": 1.0, "seed": null}, "registered_name": null, "shared_object_id": 133979648433344}, "bias_initializer": {"module": "keras.initializers", "class_name": "Zeros", "config": {}, "registered_name": null, "shared_object_id": 133979648439104}, "unit_forget_bias": true, "kernel_regularizer": null, "recurrent_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_constraint": null, "recurrent_constraint": null, "bias_constraint": null, "dropout": 0.0, "recurrent_dropout": 0.0, "seed": null}, "registered_name": null, "build_config": {"input_shape": [null, 80, 64]}}}, "registered_name": null, "build_config": {"input_shape": [null, 80, 64]}, "name": "bidirectional_1", "inbound_nodes": [{"args": [{"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 64], "dtype": "float32", "keras_history": ["encoder_embedding", 0, 0]}}], "kwargs": {"mask": null}}]}, {"module": "keras.layers", "class_name": "Dense", "config": {"name": "encoder_dense_adjust", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "units": 128, "activation": "relu", "use_bias": true, "kernel_initializer": {"module": "keras.initializers", "class_name": "GlorotUniform", "config": {"seed": null}, "registered_name": null}, "bias_initializer": {"module": "keras.initializers", "class_name": "Zeros", "config": {}, "registered_name": null}, "kernel_regularizer": null, "bias_regularizer": null, "kernel_constraint": null, "bias_constraint": null}, "registered_name": null, "build_config": {"input_shape": [null, 80, 256]}, "name": "encoder_dense_adjust", "inbound_nodes": [{"args": [{"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 256], "dtype": "float32", "keras_history": ["bidirectional_1", 0, 0]}}], "kwargs": {}}]}, {"module": "keras.src.ops.numpy", "class_name": "GetItem", "config": {"name": "get_item_1"}, "registered_name": "GetItem", "name": "get_item_1", "inbound_nodes": [{"args": [{"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 128], "dtype": "float32", "keras_history": ["encoder_dense_adjust", 0, 0]}}, [{"class_name": "__slice__", "config": {"start": null, "stop": null, "step": null}}, -1, {"class_name": "__slice__", "config": {"start": null, "stop": null, "step": null}}]], "kwargs": {}}]}, {"module": "keras.layers", "class_name": "RepeatVector", "config": {"name": "decoder_repeat_vector", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "n": 80}, "registered_name": null, "build_config": {"input_shape": [null, 128]}, "name": "decoder_repeat_vector", "inbound_nodes": [{"args": [{"class_name": "__keras_tensor__", "config": {"shape": [null, 128], "dtype": "float32", "keras_history": ["get_item_1", 0, 0]}}], "kwargs": {}}]}, {"module": "keras.layers", "class_name": "LSTM", "config": {"name": "decoder_lstm", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "return_sequences": true, "return_state": false, "go_backwards": false, "stateful": false, "unroll": false, "zero_output_for_mask": false, "units": 128, "activation": "tanh", "recurrent_activation": "sigmoid", "use_bias": true, "kernel_initializer": {"module": "keras.initializers", "class_name": "GlorotUniform", "config": {"seed": null}, "registered_name": null, "shared_object_id": 133979586961248}, "recurrent_initializer": {"module": "keras.initializers", "class_name": "OrthogonalInitializer", "config": {"gain": 1.0, "seed": null}, "registered_name": null, "shared_object_id": 133979586961344}, "bias_initializer": {"module": "keras.initializers", "class_name": "Zeros", "config": {}, "registered_name": null, "shared_object_id": 133979586961440}, "unit_forget_bias": true, "kernel_regularizer": null, "recurrent_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_constraint": null, "recurrent_constraint": null, "bias_constraint": null, "dropout": 0.0, "recurrent_dropout": 0.0, "seed": null}, "registered_name": null, "build_config": {"input_shape": [null, 80, 128]}, "name": "decoder_lstm", "inbound_nodes": [{"args": [{"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 128], "dtype": "float32", "keras_history": ["decoder_repeat_vector", 0, 0]}}], "kwargs": {"training": false, "mask": null}}]}, {"module": "keras.layers", "class_name": "Attention", "config": {"name": "attention_layer", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "use_scale": false, "score_mode": "dot", "dropout": 0.0}, "registered_name": null, "build_config": {"input_shape": [[null, 80, 128], [null, 80, 128]]}, "name": "attention_layer", "inbound_nodes": [{"args": [[{"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 128], "dtype": "float32", "keras_history": ["decoder_lstm", 0, 0]}}, {"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 128], "dtype": "float32", "keras_history": ["encoder_dense_adjust", 0, 0]}}]], "kwargs": {"training": false, "mask": [null, null]}}]}, {"module": "keras.layers", "class_name": "Concatenate", "config": {"name": "decoder_concat", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "axis": -1}, "registered_name": null, "build_config": {"input_shape": [[null, 80, 128], [null, 80, 128]]}, "name": "decoder_concat", "inbound_nodes": [{"args": [[{"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 128], "dtype": "float32", "keras_history": ["decoder_lstm", 0, 0]}}, {"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 128], "dtype": "float32", "keras_history": ["attention_layer", 0, 0]}}]], "kwargs": {}}]}, {"module": "keras.layers", "class_name": "TimeDistributed", "config": {"name": "time_distributed_1", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "layer": {"module": "keras.layers", "class_name": "Dense", "config": {"name": "decoder_output_dense", "trainable": true, "dtype": {"module": "keras", "class_name": "DTypePolicy", "config": {"name": "float32"}, "registered_name": null}, "units": 76, "activation": "softmax", "use_bias": true, "kernel_initializer": {"module": "keras.initializers", "class_name": "GlorotUniform", "config": {"seed": null}, "registered_name": null}, "bias_initializer": {"module": "keras.initializers", "class_name": "Zeros", "config": {}, "registered_name": null}, "kernel_regularizer": null, "bias_regularizer": null, "kernel_constraint": null, "bias_constraint": null}, "registered_name": null, "build_config": {"input_shape": [null, 256]}}}, "registered_name": null, "build_config": {"input_shape": [null, 80, 256]}, "name": "time_distributed_1", "inbound_nodes": [{"args": [{"class_name": "__keras_tensor__", "config": {"shape": [null, 80, 256], "dtype": "float32", "keras_history": ["decoder_concat", 0, 0]}}], "kwargs": {"mask": null}}]}], "input_layers": [["encoder_input", 0, 0]], "output_layers": [["time_distributed_1", 0, 0]]}, "registered_name": "Functional", "build_config": {"input_shape": null}, "compile_config": {"optimizer": {"module": "keras.optimizers", "class_name": "Adam", "config": {"name": "adam", "learning_rate": 0.0010000000474974513, "weight_decay": null, "clipnorm": null, "global_clipnorm": null, "clipvalue": null, "use_ema": false, "ema_momentum": 0.99, "ema_overwrite_frequency": null, "loss_scale_factor": null, "gradient_accumulation_steps": null, "beta_1": 0.9, "beta_2": 0.999, "epsilon": 1e-07, "amsgrad": false}, "registered_name": null}, "loss": "sparse_categorical_crossentropy", "loss_weights": null, "metrics": ["accuracy"], "weighted_metrics": null, "run_eagerly": false, "steps_per_execution": 1, "jit_compile": false}}