Skip to content

Input shape incompatibility  #28

@Jacopown

Description

@Jacopown

I'm running the script on a perfectly functioning conda env. I'm on a macbook pro M1.
This winter i've used this tool frequently and never had any problem, after a full reset of my laptop the tool si giving me this error:

Traceback (most recent call last):
  File "/Users/jacopown/Applications/simple-ehm/simple_ehm-runnable.py", line 455, in <module>
    analyze_track(model, waveform, sample_rate)
  File "/Users/jacopown/Applications/simple-ehm/simple_ehm-runnable.py", line 136, in timed
    output = f(*args, **kw)
  File "/Users/jacopown/Applications/simple-ehm/simple_ehm-runnable.py", line 296, in analyze_track
    prediction = model(spectrogram)
  File "/opt/homebrew/Caskroom/miniconda/base/envs/tf/lib/python3.9/site-packages/keras/utils/traceback_utils.py", line 67, in error_handler
    raise e.with_traceback(filtered_tb) from None
  File "/opt/homebrew/Caskroom/miniconda/base/envs/tf/lib/python3.9/site-packages/keras/engine/input_spec.py", line 264, in assert_input_compatibility
    raise ValueError(f'Input {input_index} of layer "{layer_name}" is '
ValueError: Input 0 of layer "sequential" is incompatible with the layer: expected shape=(None, 124, 129, 1), found shape=(1, 125, 129)
Exception ignored in: <function tqdm.__del__ at 0x150ac0a60>
Traceback (most recent call last):
  File "/opt/homebrew/Caskroom/miniconda/base/envs/tf/lib/python3.9/site-packages/tqdm/std.py", line 1162, in __del__
  File "/opt/homebrew/Caskroom/miniconda/base/envs/tf/lib/python3.9/site-packages/tqdm/std.py", line 1304, in close
  File "/opt/homebrew/Caskroom/miniconda/base/envs/tf/lib/python3.9/site-packages/tqdm/std.py", line 1301, in fp_write
TypeError: 'NoneType' object is not callable

Simply running the command as:

python3 simple_ehm-runnable.py <filename.mp4>

I don't know if it's useful:
python = 3.9.13
conda = 4.13.0
tensorflow-macos = 2.9.2
tensorflow-metal = 0.5.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions