YOLO-series icon indicating copy to clipboard operation
YOLO-series copied to clipboard

Using Flow

Open BrentHawk opened this issue 6 years ago • 6 comments

When trying to use flow to load an mp4 video to process I get the following error:

It looks like it's trying to use a camera and not load the file (just a guess).

image

BrentHawk avatar Apr 08 '18 03:04 BrentHawk

looks like an issue with darkflow not selecting the video correctly. are you trying to run yolo on a video and running from the terminal?

markjay4k avatar Apr 08 '18 04:04 markjay4k

Thanks for the response Markjay4k!!

Correct – I am trying to run yolo on the video from the terminal.

Command syntax below:

Python flow –model cfg/yolo.cfg –load bin/yolo.weights --demo people.mp4 –gpu 1.0 –saveVideo

The “people.mp4” video file is located in the base “darkflow directory” (i.e. home/bdh/darkflow).

Any ideas?

Brent

From: mark [mailto:[email protected]] Sent: Saturday, April 7, 2018 11:20 PM To: markjay4k/YOLO-series [email protected] Cc: Brent Hawkinson [email protected]; Author [email protected] Subject: Re: [markjay4k/YOLO-series] Using Flow (#10)

looks like an issue with darkflow not selecting the video correctly. are you trying to run yolo on a video and running from the terminal?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmarkjay4k%2FYOLO-series%2Fissues%2F10%23issuecomment-379519047&data=02%7C01%7Cbrentha%40microsoft.com%7Ce09fa9d0cbd04b8dea3a08d59d0804db%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C636587580127300211&sdata=%2F9D7F8YmQP1mE%2FWKGP2PQVFJH03QjU%2Bi8IA4Vsw%2BYzI%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAi0wDpjsPT7qo4HOPQcrQtvi9XUFy8fUks5tmY_5gaJpZM4TLYEQ&data=02%7C01%7Cbrentha%40microsoft.com%7Ce09fa9d0cbd04b8dea3a08d59d0804db%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C636587580127300211&sdata=xNdQkRZ7ANgHQ058sKXGJblqjR8U%2FHD9CUCFfdf40ko%3D&reserved=0.

BrentHawk avatar Apr 08 '18 14:04 BrentHawk

try running the command without python in front. so just

flow --model cfg/yolo.cfg --load bin/yolo.weights --demo people.mp4 --gpu 1.0 --saveVideo

markjay4k avatar Apr 13 '18 05:04 markjay4k

is this resolved, it is showing me an error Parsing ./cfg/yolo.cfg Parsing cfg/yolo.cfg Loading bin/yolo.weights ... Traceback (most recent call last): File "/Users/DBRSJ/anaconda/envs/tf_env/bin/flow", line 6, in cliHandler(sys.argv) File "/Users/DBRSJ/anaconda/envs/tf_env/lib/python3.6/site-packages/darkflow/cli.py", line 26, in cliHandler tfnet = TFNet(FLAGS) File "/Users/DBRSJ/anaconda/envs/tf_env/lib/python3.6/site-packages/darkflow/net/build.py", line 58, in init darknet = Darknet(FLAGS) File "/Users/DBRSJ/anaconda/envs/tf_env/lib/python3.6/site-packages/darkflow/dark/darknet.py", line 27, in init self.load_weights() File "/Users/DBRSJ/anaconda/envs/tf_env/lib/python3.6/site-packages/darkflow/dark/darknet.py", line 82, in load_weights wgts_loader = loader.create_loader(*args) File "/Users/DBRSJ/anaconda/envs/tf_env/lib/python3.6/site-packages/darkflow/utils/loader.py", line 105, in create_loader return load_type(path, cfg) File "/Users/DBRSJ/anaconda/envs/tf_env/lib/python3.6/site-packages/darkflow/utils/loader.py", line 19, in init self.load(*args) File "/Users/DBRSJ/anaconda/envs/tf_env/lib/python3.6/site-packages/darkflow/utils/loader.py", line 77, in load walker.offset, walker.size) AssertionError: expect 203934260 bytes, found 248007048 please see if this can be corrected.

InnovativeCoder avatar Apr 29 '18 23:04 InnovativeCoder

(This was written May 25th) I'm new to this field and just a user (opencv - python), this is my first time trying to use Yolo and I face the similar issue with Innovative Coder

I'm using python 3.6.5 (anaconda environment), opencv 3.4.1, tensorflow 1.8.0, gpu with cuda toolkit 9.0

Thank you very much for your help.

(Edited may 26th) I have solved my own case. Turns out that we need to use the same version for yolo configuration model (inside cfg folder) and for yolo weight file (to be put inside bin folder)

Thank you =)

advset avatar May 25 '18 15:05 advset