DeepFusionMOT icon indicating copy to clipboard operation
DeepFusionMOT copied to clipboard

FileNotFoundError

Open lx-ynu opened this issue 2 years ago • 2 comments

Hello, when I execute python main.py, I get the following error, what should I do to fix it?

Traceback (most recent call last): File "main.py", line 147, in seq_dets_3D = np.loadtxt(seq_file_3D, delimiter=',') # load 3D detections, N x 15 File "/home/miniconda3/envs/dfmot/lib/python3.8/site-packages/numpy/lib/npyio.py", line 1042, in loadtxt fh = np.lib._datasource.open(fname, 'rt', encoding=encoding) File "/home/miniconda3/envs/dfmot/lib/python3.8/site-packages/numpy/lib/_datasource.py", line 193, in open return ds.open(path, mode, encoding=encoding, newline=newline) File "/home/miniconda3/envs/dfmot/lib/python3.8/site-packages/numpy/lib/_datasource.py", line 532, in open raise FileNotFoundError(f"{path} not found.") FileNotFoundError: /media/DeepFusionMOT/datasets/kitti/train/3D_pointrcnn_Car_val\0000.txt not found.

lx-ynu avatar Jul 12 '22 07:07 lx-ynu

Hello

I guess you are running the code in Ubuntu, but it seems the author ran the code in windows. Thus the folder path has some difference in ubuntu and windows

You can go to line 17 of file_operation/file.py Change "position = detections_root + "\" + detections_file" to "position = detections_root + "/" + detections_file"

chisyliu avatar Aug 04 '22 08:08 chisyliu

Actually there are many of works need to be done for completely changing the paths from MS-DOS (Windows) to Unix. You can refer to this helpful docs and resolve them on the go, re-run each time. https://www.pythoncheatsheet.org/cheatsheet/file-directory-path#creating-new-folders Hope this help.

trThanhnguyen avatar Feb 24 '23 09:02 trThanhnguyen