Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FileNotFoundError #7

Open
lx-ynu opened this issue Jul 12, 2022 · 2 comments
Open

FileNotFoundError #7

lx-ynu opened this issue Jul 12, 2022 · 2 comments

Comments

@lx-ynu
Copy link

lx-ynu commented Jul 12, 2022

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.

@chisyliu
Copy link

chisyliu commented Aug 4, 2022

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"

@trThanhnguyen
Copy link

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants