darkflow icon indicating copy to clipboard operation
darkflow copied to clipboard

Installation Instructions for Windows 10

Open JaronrH opened this issue 6 years ago • 11 comments

Just in case anyone else had issues getting Darkflow running on Windows 10, here's the steps that I was able to use to get it working. Hopefully it will help save time for someone else!

  1. Install Python 3.5
  2. [Optional] Create virtualenv
  3. Install Tensorflow: pip3 install --upgrade tensorflow
  4. Install cython: pip3 install cython
  5. Install opencv: pip3 install opencv-python
  6. Build: python setup.py build_ext --inplace
  7. Confirm: python flow --h

JaronrH avatar Jul 20 '18 14:07 JaronrH

Hi @JaronrH ,

I get this error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools

I've VS 2017 installed. Please suggest a solution

frozenscrypt avatar Sep 04 '18 03:09 frozenscrypt

Hey @JaronrH, I have run all the steps as you described. But, when i am running step 7 then i am getting this error "AttributeError: module 'sys' has no attribute 'getdlopenflags'"

Please help me to resolve this error

junaidwahid avatar Sep 21 '18 09:09 junaidwahid

@frozenscrypt Try this? https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=BuildTools&rel=15 I think this is needed beyond just a VS2017 install.

@junaidwahid Make sure you have the latest version of Tensorflow. A quick google search makes it look like this was one of the issues running versions of Tensorflow on Windows before it supported Windows!

JaronrH avatar Sep 21 '18 12:09 JaronrH

@frozenscrypt This is the version required i think https://go.microsoft.com/fwlink/?LinkId=532606&clcid=0x409

fivecube avatar Nov 01 '18 10:11 fivecube

when i try to install

python setup.py build_ext --inplace

i get an error

python: can't open file 'setup.py': [Errno 2] No such file or directory

how can i fix this? thanks

shienaann avatar Nov 24 '18 03:11 shienaann

@shienaann , you need to check your work directory. this error : python: can't open file 'setup.py': [Errno 2] No such file or directory - means that python try to find file but couldn"t.

write this code, to check:

import os

cwd = os.getcwd() # Get the current working directory (cwd) files = os.listdir(cwd) # Get all the files in that directory print("Files in '%s': %s" % (cwd, files))

flit86 avatar Nov 28 '18 11:11 flit86

So on windows, we should also type python before flow.

doduythao avatar May 07 '19 10:05 doduythao

Just in case anyone else had issues getting Darkflow running on Windows 10, here's the steps that I was able to use to get it working. Hopefully it will help save time for someone else!

  1. Install Python 3.5
  2. [Optional] Create virtualenv
  3. Install Tensorflow: pip3 install --upgrade tensorflow
  4. Install cython: pip3 install cython
  5. Install opencv: pip3 install opencv-python
  6. Build: python setup.py build_ext --inplace
  7. Confirm: python flow --h

I stuck at 7th. It says " ModuleNotFoundError: No module named 'tensorflow.contrib' "

scorpionate avatar Apr 27 '20 13:04 scorpionate

@maksmaxx You must have directly installed tensorflow. Darkflow does not support tensorflow 2.0. You need to uninstall tensorflow and install it as pip install --upgrade tensorflow==1.15. I believe this should work.

DhirenSc avatar May 12 '20 01:05 DhirenSc

Installing the Windows 10 most-recent SDK with additional build tools https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=BuildTools&rel=16 and setting a path to - C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt solves the issue

akoustic avatar Jun 03 '20 20:06 akoustic

Installing the Windows 10 most-recent SDK with additional build tools https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=BuildTools&rel=16 and setting a path to - C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt solves the issue

Yes, this works! Didn't have to set the path, only installing the latest SDK worked for me. Thanks!

Yeaminul avatar Aug 30 '20 12:08 Yeaminul