Skip to content
Advertisement

Tag: tensorflow

Reshaping problem (Input to reshape is a tensor with 10 values, but the requested shape has 1)

I’m trying to recreate this work using my own dataset: https://www.kaggle.com/code/amyjang/tensorflow-pneumonia-classification-on-x-rays/notebook I’ve made some slight tweaks to the code to accommodate my data but I don’t think that is what is causing an issue here; it could be though of course. My code: And the error: I can gather from the error that I have a mismatch in resizing, I

Model was constructed with shape (None, 65536) but it was called on an input with incompatible shape (None, 65536, None)

For reference the full error is here: I am using kymatio to classify audio signals. Before constructing the model I use tensorflow’s tf.keras.utils.audio_dataset_from_directory to create the training and testing sets. The audio samples are of shape (65536,) before the sets are created. To create the sets I use the following code: The element_spec of the train_dataset is (TensorSpec(shape=(None, 65536, None),

Advertisement