kenshohara / 3D-ResNets-PyTorch

3D ResNets for Action Recognition (CVPR 2018)
MIT License
3.9k stars 932 forks source link

Running on Windows, convert avi to jpg. FileNotFoundError: [WinError 2] The system cannot find the specified file. #269

Closed YTHmamba closed 2 years ago

YTHmamba commented 2 years ago

Traceback (most recent call last): File "G:/C3DBLS/3D-ResNets-PyTorch-master/util_scripts/generate_video_jpgs.py", line 112, in status_list = Parallel( File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\site-packages\joblib\parallel.py", line 1056, in call self.retrieve() File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\site-packages\joblib\parallel.py", line 935, in retrieve self._output.extend(job.get(timeout=self.timeout)) File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\multiprocessing\pool.py", line 771, in get raise self._value File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\multiprocessing\pool.py", line 125, in worker result = (True, func(*args, kwds)) File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\site-packages\joblib_parallel_backends.py", line 595, in call return self.func(*args, *kwargs) File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\site-packages\joblib\parallel.py", line 262, in call return [func(args, kwargs) File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\site-packages\joblib\parallel.py", line 262, in return [func(*args, *kwargs) File "G:/C3DBLS/3D-ResNets-PyTorch-master/util_scripts/generate_video_jpgs.py", line 65, in class_process video_process(video_file_path, dst_class_path, ext, fps, size) File "G:/C3DBLS/3D-ResNets-PyTorch-master/util_scripts/generate_video_jpgs.py", line 17, in video_process p = subprocess.run(ffprobe_cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE) File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\subprocess.py", line 493, in run with Popen(popenargs, **kwargs) as process: File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\subprocess.py", line 858, in init self._execute_child(args, executable, preexec_fn, close_fds, File "C:\Users\yangtianhao\anaconda3\envs\resnet3d\lib\subprocess.py", line 1311, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] The system cannot find the specified file.

guilhermesurek commented 2 years ago

Hello @YTHmamba, I saw your post in the issue #241, it's the same problem. I suggest you printing the video files name and when the error raises check if the file exists. If it's confirmed, you will need to add in your code a 'file exist validation' before running "video_process(video_file_path, dst_class_path, ext, fps, size)".

YTHmamba commented 2 years ago

你好@YTHmamba,我在 issue #241看到你的帖子,这是同样的问题。我建议您打印视频文件名,并在出现错误时检查文件是否存在。如果确认,您需要在运行“video_process(video_file_path, dst_class_path, ext, fps, size)”之前在代码中添加“文件存在验证”。

thanks ,i get it