Comments (3)
If you're using one of the models that isn't trained on the COCO dataset then you have to use the --classes_path
path flag to specify the classes the model is trained on. You can find the list of PASCAL VOC classes in model_data/pascal_classes.txt
.
Also if you're using a model not trained on COCO then you need to give the --anchors_path
to specify the anchor boxes the model was trained with. These are saved separately when you run yad2k.py
, e.g. as model_data/tiny-yolo-voc_anchors.txt
. (I believe all the COCO models use the same anchors and likewise for the VOC models.)
In the future I may try to get these saved as part of the model file itself. For now I've expanded the error message to inform the user about these flags.
(Also note that tiny-yolo-voc is a small model with poor performance so it will make mistakes on the included test images.)
from yad2k.
Thanks for the reply. It works by adding the path, but I get another error:
./test_yolo.py model_data/tiny-yolo-voc.h5 --classes_path model_data/pascal_classes.txt --anchors_path model_data/tiny-yolo-voc_anchors.txt
model was *not* compiled. Compile it manually.
warnings.warn('No training configuration found in save file: '
model_data/tiny-yolo-voc.h5 model, anchors, and classes loaded.
Traceback (most recent call last):
File "./test_yolo.py", line 186, in <module>
_main(parser.parse_args())
File "./test_yolo.py", line 107, in _main
yolo_outputs = yolo_head(yolo_model.output, anchors, len(class_names))
File "/Users/xslittlegrass/Deep_learning/YAD2K/yad2k/models/keras_yolo.py", line 100, in yolo_head
conv_height_index = K.arange(0, stop=conv_dims[0])
AttributeError: module 'keras.backend' has no attribute 'arange'
Exception ignored in: <bound method BaseSession.__del__ of <tensorflow.python.client.session.Session object at 0x12a0bd898>>
Traceback (most recent call last):
File "/Users/xslittlegrass/anaconda3/lib/python3.5/site-packages/tensorflow/python/client/session.py", line 581, in __del__
AttributeError: 'NoneType' object has no attribute 'TF_DeleteStatus'
Do you have any ideas? Thanks.
from yad2k.
This problem is solved by upgrading keras.
from yad2k.
Related Issues (20)
- weird error
- when trying'./yad2k.py yolo.cfg yolo.weights model_data/yolo.h5', has problem HOT 2
- retrain_yolo image size/shape (416,416 vs 416,416,3)
- Difference between yad2k.py and yad2k/models/keras_yolo.py?
- Replace session.run() with keras Model
- ValueError: Cannot feed value of shape (1, 416, 416) for Tensor 'input_1:0', which has shape '(?, 416, 416, 3)' HOT 2
- The bounding box shifts
- The bounding box shifts right or left from the target.
- I try to generate yolo.h5 and use this command: python yad2k.py yolo.cfg yolo.weights model_data/yolo.h5 HOT 4
- when I run the code "yolo_model = load_model("model_data/yolov2.h5")" always raise an error HOT 1
- Using darknet19 as a simple classifier
- AttributeError: Module 'tensorflow' has no attribute 'space_to_depth" HOT 4
- issue with model last layer
- Generate yolo.h5 file HOT 1
- detects only 10 objects on max
- wget yolo cfg doesn't work HOT 1
- ReLu Activation Function HOT 1
- convert yolo9000.weights error
- Attempting to use uninitialized value FeatureExtractor/MobilenetV2/expanded_conv_3/depthwise/BatchNorm/beta [[{{node _retval_FeatureExtractor/MobilenetV2/expanded_conv_3/depthwise/BatchNorm/beta_0_179}}]] HOT 1
- issues with config_path weights_path output_path
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yad2k.