Unknown layer: AnchorBoxes
See original GitHub issueSorry ,I’m s a rookie in keras & Neural network. Pardom,can I ask you a question?
I complete the model training and save model & weights,but when I want to load model next time ,
there will be mistakes : ValueError: Unknown layer: AnchorBoxes
#load model && load weights model = load_model('./model/ssd7_0.h5') model.load_weights('./model/ssd7_0_weights.h5')
I really want to know how to solve this problem,would like to ask about the experienced elders.
thankes!
Issue Analytics
- State:
- Created 6 years ago
- Comments:10 (5 by maintainers)
Top Results From Across the Web
Unknown layer: AnchorBoxes quantization tensorflow
I am applying quantization to a SSD model. The gist is attached. There is a custom object called "AnchorBoxes ...
Read more >Unknown Layer: Anchorboxes Quantization ... - ADocLib
In this paper we go further in robotic grasp detection with fully convolutional neural network and oriented anchor boxes which are proved to...
Read more >keras.models.load_model ValueError: Unknown layer
ValueError: Unknown layer: Functional. i'm using the following command in python: from tensorflow import keras.
Read more >Detect objects using YOLO v4 object detector - MATLAB
The yolov4ObjectDetector object creates a you only look once version 4 (YOLO v4) one-stage object detector for detecting objects in an image.
Read more >FPN_CNN_Object_detection_Cu...
This class has operations to generate anchor boxes for feature maps ... Layer): """Builds the Feature Pyramid with the feature maps from the ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@gloddream There definitely is, i just haven’t figured out how yet. i’ve recently implemented the
get_config()
method in both of the custom layers (L2Normalization and AnchorBoxes), so you should theoretically be able to load the model usingmodel = load_model('./model/ssd7_0.h5', custom_objects={'AnchorBoxes': AnchorBoxes, 'L2Normalization': L2Normalization, 'SSDLoss': SSDLoss})
but for some reason either
model.save
orload_model
isn’t able to use the dictionaries thatget_config()
provides correctly. Since Keras documentation regarding saving and loading models with custom objects is basically non-existent and as far as I can tell I implemented the relevant methods in my layers exactly like the Keras core layers implement them, I didn’t bother trying around any longer since I had other stuff to do. If you figure out how to make it work, let me know 🙂The above mentioned problem is now resolved under tensorflow/model-optimization#620.
All thanks to @Hackerman28 !! 😄