darkflow icon indicating copy to clipboard operation
darkflow copied to clipboard

This error came when i test cfg/tiny-yolo-voc-1c.cfg .my mode after training the data . Any one can help please

Open sharoseali opened this issue 6 years ago • 11 comments

C:\Users\MIPRG-P2\Anaconda3\lib\site-packages\h5py_init_.py:36: FutureWarning: Conversion of the second argument of issubdtype from float to np.floating is deprecated. In future, it will be treated as np.float64 == np.dtype(float).type. from ._conv import register_converters as _register_converters WARNING:tensorflow:From C:\Users\MIPRG-P2\Anaconda3\lib\site-packages\tensorflow\contrib\learn\python\learn\datasets\base.py:198: retry (from tensorflow.contrib.learn.python.learn.datasets.base) is deprecated and will be removed in a future version. Instructions for updating: Use the retry module or similar alternatives. Parsing cfg/tiny-yolo-voc-1c.cfg Traceback (most recent call last): File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\realtimeDetection.py", line 10, in tfnet = TFNet(options) File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\net\build.py", line 58, in init darknet = Darknet(FLAGS) File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\dark\darknet.py", line 17, in init src_parsed = self.parse_cfg(self.src_cfg, FLAGS) File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\dark\darknet.py", line 68, in parse_cfg for i, info in enumerate(cfg_layers): File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\utils\process.py", line 66, in cfg_yielder layers, meta = parser(model); yield meta; File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\utils\process.py", line 17, in parser with open(model, 'rb') as f: FileNotFoundError: [Errno 2] No such file or directory: 'cfg/tiny-yolo-voc-1c.cfg'

sharoseali avatar May 18 '18 06:05 sharoseali

the Error occurs when i test my cfg file named tiny-yolo-voc-1c.cfg.. after training the dataset. Any one who can help me . I am using darkflow on windows

sharoseali avatar May 18 '18 06:05 sharoseali

Please check the file cfg/tiny-yolo-voc-1c.cfg is existed.

youyuge34 avatar May 20 '18 07:05 youyuge34

yes the file exists .. this is the issue the even a file exists it show me this message however i give full path and darkflow respond me like this

WARNING:tensorflow:From C:\Users\MIPRG-P2\Anaconda3\lib\site-packages\tensorflow\contrib\learn\python\learn\datasets\base.py:198: retry (from tensorflow.contrib.learn.python.learn.datasets.base) is deprecated and will be removed in a future version. Instructions for updating: Use the retry module or similar alternatives. Parsing C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\cfg\tiny-yolo-voc-1c.cfg Traceback (most recent call last): File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\realtimeDetection.py", line 12, in tfnet = TFNet(options) File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\net\build.py", line 64, in init self.framework = create_framework(*args) File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\net\framework.py", line 59, in create_framework return this(meta, FLAGS) File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\net\framework.py", line 15, in init self.constructor(meta, FLAGS) File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\net\yolo_init_.py", line 20, in constructor misc.labels(meta, FLAGS) #We're not loading from a .pb so we do need to load the labels File "C:\Users\MIPRG-P2\Desktop\dark\darkflow-master\darkflow\net\yolo\misc.py", line 36, in labels with open(file, 'r') as f: FileNotFoundError: [Errno 2] No such file or directory: 'labels.txt' Loading None ... Finished in 0.0s [Finished in 5.002s]

sharoseali avatar May 20 '18 07:05 sharoseali

E:\Users\ZP\Desktop\Getdata>flow.py --model cfg/yolov2-tiny-voc.cfg --load bin/yolov2-tiny-voc.weights --savepb

Parsing ./cfg/yolov2-tiny-voc.cfg Parsing cfg/yolov2-tiny-voc.cfg Loading bin/yolov2-tiny-voc.weights ... Successfully identified 63102560 bytes Finished in 0.04497408866882324s Traceback (most recent call last): File "E:\Users\ZP\Desktop\Getdata\flow.py", line 6, in cliHandler(sys.argv) File "D:\Program Files\Python36\lib\site-packages\darkflow\cli.py", line 26, in cliHandler tfnet = TFNet(FLAGS) File "D:\Program Files\Python36\lib\site-packages\darkflow\net\build.py", line 64, in init self.framework = create_framework(*args) File "D:\Program Files\Python36\lib\site-packages\darkflow\net\framework.py", line 59, in create_framework return this(meta, FLAGS) File "D:\Program Files\Python36\lib\site-packages\darkflow\net\framework.py", line 15, in init self.constructor(meta, FLAGS) File "D:\Program Files\Python36\lib\site-packages\darkflow\net\yolo_init_.py", line 20, in constructor misc.labels(meta, FLAGS) #We're not loading from a .pb so we do need to load the labels File "D:\Program Files\Python36\lib\site-packages\darkflow\net\yolo\misc.py", line 36, in labels with open(file, 'r') as f: FileNotFoundError: [Errno 2] No such file or directory: 'labels.txt'

JoffreyN avatar Jul 19 '18 08:07 JoffreyN

@sharoseali Did you solve it?

JoffreyN avatar Jul 19 '18 08:07 JoffreyN

JofferyN... he command u r using is usually used when we train our own data set.. to save pb file... this command will work when u specify your labels file explicitly by using --labels filname

where filename is gile where u wil define your class names or labels on which your model is trained

On Thu, Jul 19, 2018, 2:00 PM JoffreyN [email protected] wrote:

@sharoseali https://github.com/sharoseali Did you solve it?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/thtrieu/darkflow/issues/764#issuecomment-406206527, or mute the thread https://github.com/notifications/unsubscribe-auth/AS8u8p6r4XBVRLHJcoRwZjJ8hbequGMjks5uIEqVgaJpZM4UENze .

sharoseali avatar Jul 19 '18 09:07 sharoseali

@sharoseali kindly take a look at the error it's giving: FileNotFoundError: [Errno 2] No such file or directory: 'labels.txt' which means the file "labels.txt" is not found in the current directory. Please check your folder structure once.

masteroogway97 avatar Apr 21 '19 03:04 masteroogway97

@sharoseali @JoffreyN Did you guys solve it?

masteroogway97 avatar Sep 12 '19 13:09 masteroogway97

@sharoseali Did you solve it?

I solved it by switching the slash in my options. I was on windows 10 and was getting below error: FileNotFoundError: [Errno 2] No such file or directory: 'cfg/tiny-yolo-voc-1c.cfg'

I had options as:

options = {
    'model': 'cfg\tiny-yolo-voc-1c.cfg',
    :
    : 
}

I changed it to:

options = {
    'model': 'cfg/tiny-yolo-voc-1c.cfg',
    : 
    :
}

gokadroid avatar Nov 29 '19 18:11 gokadroid

Parsing ./cfg/tiny-yolo-voc.cfg Parsing cfg/tiny-yolo-voc-7c.cfg Traceback (most recent call last): File "flow", line 6, in cliHandler(sys.argv) File "/home/mirait/Desktop/cvyolo/darkflow/darkflow/cli.py", line 26, in cliHandler tfnet = TFNet(FLAGS) File "/home/mirait/Desktop/cvyolo/darkflow/darkflow/net/build.py", line 58, in init darknet = Darknet(FLAGS) File "/home/mirait/Desktop/cvyolo/darkflow/darkflow/dark/darknet.py", line 24, in init des_parsed = self.parse_cfg(FLAGS.model, FLAGS) File "/home/mirait/Desktop/cvyolo/darkflow/darkflow/dark/darknet.py", line 68, in parse_cfg for i, info in enumerate(cfg_layers): File "/home/mirait/Desktop/cvyolo/darkflow/darkflow/utils/process.py", line 66, in cfg_yielder layers, meta = parser(model); yield meta; File "/home/mirait/Desktop/cvyolo/darkflow/darkflow/utils/process.py", line 17, in parser with open(model, 'rb') as f: FileNotFoundError: [Errno 2] No such file or directory: 'cfg/tiny-yolo-voc-7c.cfg'

i have above mentioned problem. I don't know what's wrong.

I've kept the filters to 60 as I've seven classes of dataset. And those models are right there in the cfg file(file does exist). I even changed the labels as well. any help would be appreciated.

Narayanprasai avatar Mar 06 '20 09:03 Narayanprasai

Check the directory structure that you've created and placed those files in.

masteroogway97 avatar Mar 14 '20 11:03 masteroogway97