FileNotFoundError: [WinError 2] The system cannot find the file specified
santuc93 opened this issue · 3 comments
Hi All,
while executing facing following error
code :
import sox
sox.file_info.sample_rate("C:\Temp\RecordedFile.wav")
Error:'sox' is not recognized as an internal or external command,
operable program or batch file.
SoX could not be found!
If you do not have SoX, proceed here:
- - - http://sox.sourceforge.net/ - - -
If you do (or think that you should) have SoX, double-check your
path variables.
This install of SoX cannot process .wav files.
Traceback (most recent call last):
File "C:\Users\santho9x\OneDrive - Intel Corporation\Desktop\examples\ABC.py", line 3, in
sox.file_info.sample_rate("C:/Temp/RecordedFile.wav")
File "C:\Users\santho9x\AppData\Local\Programs\Python\Python37\lib\site-packages\sox\file_info.py", line 205, in sample_rate
output = soxi(input_filepath, 'r')
File "C:\Users\santho9x\AppData\Local\Programs\Python\Python37\lib\site-packages\sox\core.py", line 149, in soxi
stderr=subprocess.PIPE
File "C:\Users\santho9x\AppData\Local\Programs\Python\Python37\lib\subprocess.py", line 411, in check_output
**kwargs).stdout
File "C:\Users\santho9x\AppData\Local\Programs\Python\Python37\lib\subprocess.py", line 488, in run
with Popen(*popenargs, **kwargs) as process:
File "C:\Users\santho9x\AppData\Local\Programs\Python\Python37\lib\subprocess.py", line 800, in init
restore_signals, start_new_session)
File "C:\Users\santho9x\AppData\Local\Programs\Python\Python37\lib\subprocess.py", line 1207, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified
Notes:
we can see file in provided location.
could you please help here
Regards ,
Santhosh
Hi Santhosh,
Even i have tried and facing the same issue for this.
Can someone can help here in this forum to resolve the issue?
Regards,
Vinoth P B
I too got this failure, Any workaround available ?
Thanks in advance !
chow3
Hi all,
It looks like the sox command line tool is not installed on your system. Please have a look at the Installation Instructions for how to resolve it.
closing, as this isn't a bug with pysox!