Darkflow: Installation Issues

Created on 3 Jul 2017  路  15Comments  路  Source: thtrieu/darkflow

I installed with pip install . Is there anything else that I should do after this step?

Then I tried to execute this
./flow --model cfg/yolo-new.cfg and I got the following error
No module named cy_yolo_findboxes

Looked at other issues such as #168 but the solutions are not consistent with the current repo

for example (From #168 )
cd ./cython_utils python3 setup.py build_ext --inplace cd ..

The directory cython_utils doesn't contain the setup.py in the firstplace, because setup.py appears to be in darkflow-master directory, So I tried executing it in that directory and I got this error
No module named 'setuptools'

Any Hints?

Most helpful comment

I solved the problem, by installing using pip install -e .
I was using the in-place install at first

All 15 comments

Hello,
just cloned the repo , and got the same issue :
No module named cy_yolo_findboxes
any help would would be appreciated !

Instead of running with ./flow can you try just using flow and see if that works?

can you try just using flow and see if that works?

got flow: command not found

I solved the problem, by installing using pip install -e .
I was using the in-place install at first

@eslamahmedkhair Is this working for you now? If you installed using pip install . or pip install -e . then the flow command should be available globally. If you build the cython extensions in place you have to use ./flow in the folder where darkflow is placed.

it seems that the first installation was unsuccessful because I needed admin rights (i.e. sudo)
Works like a charm now!

One more thing please,

I tried to execute
flow --imgdir sample_img/ --model cfg/yolo-tiny.cfg --load bin/yolo-tiny.weights --gpu 1.0
but I changed --model cfg/yolo-tiny.cfg to --model cfg/tiny-yolo.cfg to match the file name provided in the cfg directory and I got the following errorAssertionError: expect 64701556 bytes, found 180357512

Make sure you download the right weights for the correct model. (I think you download the yolo-tiny weights from COCO not from VOC)

Still I downloaded yolo-voc.weights from darknet and executed:
flow --imgdir sample_img/ --model cfg/yolo-voc.cfg --load bin/yolo-voc.weights --gpu 1.0
and got: Over-read bin/yolo-voc.weights

OK, so I managed to run the following:
flow --imgdir sample_img/ --model cfg/yolo-voc.cfg --load bin/yolo.weights --gpu 1.0
however, there was no detections at all!! (yolo.weights was obtained from here )

but this: flow --imgdir sample_img/ --model cfg/tiny-yolo-voc.cfg --load bin/tiny-yolo-voc.weights --gpu 1.0
did some detections but the quality/accuracy was too low as this is the tiny model (tiny-yolo-voc.weights was obtained from here)

Any reason why the yolo-voc.weights produces no detections?!

HINT: Use all the cfgs and weights from here, the ones that are provided within the repo has be tempered with somehow!

I'm having some difficulties and would appreciate any help you can provide. I've copied the weights in the bin folder and am now receiving the following error: (newcvtest)

bash-3.2$ flow --model cfg/yolo-tiny.cfg --load bin/tiny-yolo.weights
Traceback (most recent call last):
File "/anaconda3/bin/flow", line 4, in
__import__('pkg_resources').require('darkflow==1.0.0')
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 3147, in
@_call_aside
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 3131, in _call_aside
f(args, *kwargs)
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 3160, in _initialize_master_working_set
working_set = WorkingSet._build_master()
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 666, in _build_master
ws.require(__requires__)
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 984, in require
needed = self.resolve(parse_requirements(requirements))
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 870, in resolve
raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'darkflow==1.0.0' distribution was not found and is required by the application
(newcvtest) bash-3.2$

Darkflow is installed, so I'm not certain what's wrong here. Your feedback is greatly appreciated!

did somebody find out the problem with the error message?
pkg_resources.DistributionNotFound: The 'darkflow==1.0.0' distribution was not found and is required by the application

I have the same issue

I have the same issue as well

Traceback (most recent call last):
File "/usr/local/bin/flow", line 4, in
__import__('pkg_resources').require('darkflow==1.0.0')
File "/home/jakup/.local/lib/python3.5/site-packages/pkg_resources/__init__.py", line 3088, in
@_call_aside
File "/home/jakup/.local/lib/python3.5/site-packages/pkg_resources/__init__.py", line 3072, in _call_aside
f(args, *kwargs)
File "/home/jakup/.local/lib/python3.5/site-packages/pkg_resources/__init__.py", line 3101, in _initialize_master_working_set
working_set = WorkingSet._build_master()
File "/home/jakup/.local/lib/python3.5/site-packages/pkg_resources/__init__.py", line 574, in _build_master
ws.require(__requires__)
File "/home/jakup/.local/lib/python3.5/site-packages/pkg_resources/__init__.py", line 892, in require
needed = self.resolve(parse_requirements(requirements))
File "/home/jakup/.local/lib/python3.5/site-packages/pkg_resources/__init__.py", line 778, in resolve
raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'darkflow==1.0.0' distribution was not found and is required by the application

Same issue.

Please, someone help me, I am having the same issue. After running the flow command, it opens a file containing,

!C:\Users\rgoesAnaconda3\python.exe

EASY-INSTALL-DEV-SCRIPT: 'darkflow==1.0.0','flow'

__requires__ = 'darkflow==1.0.0'
__import__('pkg_resources').require('darkflow==1.0.0')
__file__ = 'C:\RenaultProjects\yolo_project\darkflow\flow'
exec(compile(open(__file__).read(), __file__, 'exec'))

Best,

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Kowasaki picture Kowasaki  路  4Comments

bareblackfoot picture bareblackfoot  路  5Comments

humanova picture humanova  路  4Comments

ma3252788 picture ma3252788  路  3Comments

eugtanchik picture eugtanchik  路  4Comments