Giter VIP home page Giter VIP logo

Comments (3)

allanzelener avatar allanzelener commented on July 16, 2024

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.

xslittlegrass avatar xslittlegrass commented on July 16, 2024

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.

xslittlegrass avatar xslittlegrass commented on July 16, 2024

This problem is solved by upgrading keras.

from yad2k.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.