Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when running on webcam #74

Open
Delesoft opened this issue Dec 16, 2021 · 1 comment
Open

Error when running on webcam #74

Delesoft opened this issue Dec 16, 2021 · 1 comment

Comments

@Delesoft
Copy link

Hallo,i am trying to run the model on webcam but i get the following error

$ python detect_video.py --weights ./checkpoints/yolov4-416 --size 416 --model yolov4 --video 0 --output ./detections/results.avi
Traceback (most recent call last):
File "detect_video.py", line 178, in
app.run(main)
File "C:\Users\paulm\AppData\Roaming\Python\Python37\site-packages\absl\app.py", line 312, in run
_run_main(main, args)
File "C:\Users\paulm\AppData\Roaming\Python\Python37\site-packages\absl\app.py", line 258, in _run_main
sys.exit(main(argv))
File "detect_video.py", line 56, in main
saved_model_loaded = tf.saved_model.load(FLAGS.weights, tags=[tag_constants.SERVING])
File "C:\Program Files\Python37\lib\site-packages\tensorflow\python\saved_model\load.py", line 590, in load
return load_internal(export_dir, tags, options)
File "C:\Program Files\Python37\lib\site-packages\tensorflow\python\saved_model\load.py", line 601, in load_internal
loader_impl.parse_saved_model_with_debug_info(export_dir))
File "C:\Program Files\Python37\lib\site-packages\tensorflow\python\saved_model\loader_impl.py", line 56, in parse_saved_model_with_debug_info
saved_model = _parse_saved_model(export_dir)
File "C:\Program Files\Python37\lib\site-packages\tensorflow\python\saved_model\loader_impl.py", line 113, in parse_saved_model
constants.SAVED_MODEL_FILENAME_PB))
OSError: SavedModel file does not exist at: ./checkpoints/yolov4-416/{saved_model.pbtxt|saved_model.pb}

@huzaifah-here
Copy link

Try this:
python detect_video.py --weights ./checkpoints/custom-416 --size 416 --model yolov4 --video 0 --output ./detections/results.avi

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants