handwritten-flowchart-with-cnn
handwritten-flowchart-with-cnn copied to clipboard
Exception: Weight count mismatch for layer #20 (named time_distributed_1). Layer expects 2 weight(s). Received 0 saved weight(s)
Hello and thanks for this software!
I could not easily install it simply by the requirements file, but I had to struggle some hours, finally getting it to work (almost).
In the working configuration I am using python 3.9 (no chance with 3.7 and 3.8, or 3.10 and 3.11) in miniconda, ubuntu 20.04 in wsl2. After installing python, I used the requirements file but I had then to:
- make some installations manually (details available, of course, if someone is interested)
- change in cnn.py:
#from keras.engine.topology import get_source_inputs
from keras.utils.layer_utils import get_source_inputs
Now the GUI starts.
I can:
- go to the "recognize flowchart" menu,
- select the "9" folder for the traning results,
- load an input image,
- click on "predict"
but I get:
Using Conda env: handwritten-flowchart-recog Config loaded successful!! Loading weights from model/training_results/9/flowchart_3b_model.hdf5 Exception: Weight count mismatch for layer #20 (named time_distributed_1). Layer expects 2 weight(s). Received 0 saved weight(s) Couldn't load pretrained model weights!
What may the problem be? Too tired now to try anything myself... Thanks! Best Giorgio
Is it possible that the format of the trained network, saved into flowchart_3b_model.hdf5, has changed with time so that it is no more compatible with newer software?
Just to give complete information, I retried on another pc, and python 3.7 worked. Everything else I wrote in the preceding messages remains true: I still have:
Loading weights from model/training_results/9/flowchart_3b_model.hdf5 Exception: Weight count mismatch for layer #20 (named time_distributed_1). Layer expects 2 weight(s). Received 0 saved weight(s) Couldn't load pretrained model weights!
I meet the same question . do you have solve it? thank you very much
No, sorry.... :-(
我已经收到你的邮件
Is it possible that the format of the trained network, saved into flowchart_3b_model.hdf5, has changed with time so that it is no more compatible with newer software?
Hello,
No, it hasn't changed, I will check this issue
我已经收到你的邮件