[SOLVED] AssertionError: Tried to export a function which references untracked resource

Issue I wrote a unit-test in order to safe a model after noticing that I am not able to do so (anymore) during training. @pytest.mark.usefixtures("maybe_run_functions_eagerly") def test_save_model(speech_model: Tuple[TransducerBase, SpeechFeaturesConfig]): model, speech_features_config = speech_model speech_features_config: SpeechFeaturesConfig channels = 3 if speech_features_config.add_delta_deltas

Continue reading

[SOLVED] LSTM model: ValueError: Input 0 of layer "lstm" is incompatible with the layer: expected ndim=3, found ndim=2. Full shape received: (None, 7)

Issue I am building a keras model for a multi-class classification problem. my data set has 7 numerical features and 4 labels. I have structured the model as follows: def create_keras_model(): initializer = tf.keras.initializers.GlorotNormal() return tf.keras.models.Sequential([ #tf.keras.layers.Input(shape=(7,)), LSTM(units=20,kernel_initializer = initializer

Continue reading

[SOLVED] RaggedTensor request to TensorFlow serving fails

Issue I’ve created a TensorFlow model that uses RaggedTensors. Model works fine and when calling model.predict and I get the expected results. input = tf.ragged.constant([[[-0.9984272718429565, -0.9422321319580078, -0.27657580375671387, -3.185823678970337, -0.6360141634941101, -1.6579184532165527, -1.9000954627990723, -0.49169546365737915, -0.6758883595466614, -0.6677696704864502, -0.532067060470581], [-0.9984272718429565, -0.9421600103378296, 2.2048349380493164, -1.273996114730835, -0.6360141634941101,

Continue reading