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

Error processing unexpected EOF, expected 6972 more bytes. The file might be corrupted. #3

Open
unjerry opened this issue Nov 24, 2024 · 1 comment

Comments

@unjerry
Copy link

unjerry commented Nov 24, 2024

I'm on the Windows11 system using both 3.11 and 3.10.6 installed on my computer, the "python" command will call 3.10.6 first(the 3.10.6 in the path is in the more ahead place). I use both the release and the git clone method, and open the cmd in the "install.bat" folder, and after it runs done and installed all the dependencies in the ./vene i use the audio2vmd.py

i runed
python .\audio2vmd\audio2vmd.py .\1124.MP3
python .\audio2vmd.py .\1124.MP3
and i also use the gui

and get the following error.
the console in the gui also give the same error.

Processing file 1 of 1: 1124.MP3
separate_vocals_mode = automatic
Torchaudio failed to load audio for analysis, trying pydub...
Using pydub for audio analysis instead of Torchaudio (this is normal, both methods work well)...
Error processing 1124.MP3: unexpected EOF, expected 6972 more bytes. The file might be corrupted.
Total time taken: 0.88 seconds
Complete! All Audio to VMD conversion completed in 0.90 seconds.

I'm not sure what it the current situation. please check this bug if you need more information , please tell me, i will make more test.

@EliseWindbloom
Copy link
Owner

EliseWindbloom commented Nov 24, 2024

Hi unjerry,
thanks for the report. Based on the error message, it sounds like there could possibly be some corruption in the mp3 file you're playing(the bytes at the end of the mp3 file isn't what's expected).

The error appears to be occurring during audio file analysis in the analyze_audio_for_vocals() function, specifically when trying to load the audio file using pydub.
From what info i could find online, the error "unexpected EOF, expected 6972 more bytes" typically means either: the MP3 file is corrupted/incomplete, the file may be DRM protected, or there could be codec/format issues.

Did you get this error with any other audio files as well with audio2vmd? Also could you tell me how much RAM does your pc have?

During installation, did audio2vmd install without any errors? Since I've removed spleeter from in audio2vmd version 16, it likely should be much less strict on installation and not necessary require python 3.10.6. But I've kept it as that in the read me just in case, since that's what i've tested it on.

I've tried audio2vmd in cmd mode and with the ".\" string in the path but i wasn't able to reproduce your error or any others. Though, from the error you're getting, it sounds like it's most likely the audio file.

  • Note, currently when using it directly with cmd, the output folder is dependent on your current directory in cmd(unless you specify with --output), so it's recommended that you either navigate to the same folder audio2vmd.py is located in (like shown in the readme):
    cd audio2vmd  
    call venv\Scripts\activate.bat
    python audio2vmd.py 1124.MP3
    
  • or you give it the full path to the desired output folder like this if you want to call audio2vmd.py while in a different directory:
    call venv\Scripts\activate.bat
    python \audio2vmd\audio2vmd.py 1124.MP3 --output "C:\files\vmd\"
    

Anyways, to hopefully fix your problem, please try the following:

  • Try downloading this song The Hound Song (public domain) via wikimedia and run it with audio2vmd to see if you still have that same error.
  • If you want to use that specific mp3 file too, first try opening it with something like audacity, and export it as an wav file to remove any possible corruption(assuming corruption is the problem). Then try that new file with audio2vmd again.
  • If you still get the same error, you could try different audio files in different formats (mp3/wav/ogg and such) to see if it still has the error.

Hopefully this will be solve the problem, but if not, please give me the full error log and i'll try to take a look and 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

2 participants