Skip to content
This repository has been archived by the owner on Aug 5, 2023. It is now read-only.

Pass video without the json file #20

Open
BatoolHamawi opened this issue May 15, 2022 · 1 comment
Open

Pass video without the json file #20

BatoolHamawi opened this issue May 15, 2022 · 1 comment

Comments

@BatoolHamawi
Copy link

@kaylode thanks for great work !
How to run the code with new video that don't have the json file that include annotations as in demo folder, I have multiple videos and I want to use the pretrained model on them

!python run.py --input_path='/content/main/demo/sample/cam_04.mp4' \
              --output_path="/content/results" \
              --weight="/content/gdrive/MyDrive/best.pt"

as we can see we should have a json file in the same folder (demo/sample) with the video and it must have the same name, what if we want to pass a new video that don't have a json of annotations ?

@AhmedHefnawy
Copy link

is it run successfully !!
i can't run it successfully
it's give me an error :

Traceback (most recent call last):
File "C:\AhmedHefnawy\buy\altr\vehicle-counting-master\vehicle-counting-master\run.py", line 48, in
main(args, config)
File "C:\AhmedHefnawy\buy\altr\vehicle-counting-master\vehicle-counting-master\run.py", line 30, in main
pipeline.run()
File "C:\AhmedHefnawy\buy\altr\vehicle-counting-master\vehicle-counting-master\modules_init_.py", line 31, in run
videoloader = VideoLoader(self.config, video_path)
File "C:\AhmedHefnawy\buy\altr\vehicle-counting-master\vehicle-counting-master\modules\datasets.py", line 89, in init
dataset = VideoSet(config, video_path)
File "C:\AhmedHefnawy\buy\altr\vehicle-counting-master\vehicle-counting-master\modules\datasets.py", line 24, in init
self.initialize_stream()
File "C:\AhmedHefnawy\buy\altr\vehicle-counting-master\vehicle-counting-master\modules\datasets.py", line 46, in initialize_stream
assert 0, f"Cannot read video {os.path.basename(self.input_path)}"
AssertionError: Cannot read video cam_04.mp4'

Can you help ?!!

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

No branches or pull requests

2 participants