RVC-Project / RVC-Project/Retrieval-based-Voice-Conversion-WebUI

Who can help me?AttributeError: 'NoneType' object has no attribute 'dtype'

Open
#2,647 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
38.4k
Forks
5.3k
PR merge metrics
No merged PRs in 30d

Description

File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\infer\lib\audio.py", line 63, in load_audio
audio2(f, out, "f32le", sr)
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\infer\lib\audio.py", line 44, in audio2
for frame in inp.decode(audio=0):
File "av\container\input.pyx", line 203, in decode
File "av\packet.pyx", line 87, in av.packet.Packet.decode
File "av\stream.pyx", line 172, in av.stream.Stream.decode
File "av\codec\context.pyx", line 524, in av.codec.context.CodecContext.decode
File "av\codec\context.pyx", line 427, in av.codec.context.CodecContext._send_packet_and_recv
File "av\error.pyx", line 336, in av.error.err_check
av.error.InvalidDataError: [Errno 1094995529] Invalid data found when processing input; last error log: [mp3float] Header missing

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\infer\modules\vc\modules.py", line 163, in vc_single
audio = load_audio(input_audio_path, 16000)
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\infer\lib\audio.py", line 73, in load_audio
raise RuntimeError(traceback.format_exc())
RuntimeError: Traceback (most recent call last):
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\infer\lib\audio.py", line 63, in load_audio
audio2(f, out, "f32le", sr)
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\infer\lib\audio.py", line 44, in audio2
for frame in inp.decode(audio=0):
File "av\container\input.pyx", line 203, in decode
File "av\packet.pyx", line 87, in av.packet.Packet.decode
File "av\stream.pyx", line 172, in av.stream.Stream.decode
File "av\codec\context.pyx", line 524, in av.codec.context.CodecContext.decode
File "av\codec\context.pyx", line 427, in av.codec.context.CodecContext._send_packet_and_recv
File "av\error.pyx", line 336, in av.error.err_check
av.error.InvalidDataError: [Errno 1094995529] Invalid data found when processing input; last error log: [mp3float] Header missing

Traceback (most recent call last):
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\runtime\lib\site-packages\gradio\routes.py", line 321, in run_predict
output = await app.blocks.process_api(
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\runtime\lib\site-packages\gradio\blocks.py", line 1007, in process_api
data = self.postprocess_data(fn_index, result["prediction"], state)
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\runtime\lib\site-packages\gradio\blocks.py", line 953, in postprocess_data
prediction_value = block.postprocess(prediction_value)
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\runtime\lib\site-packages\gradio\components.py", line 2076, in postprocess
processing_utils.audio_to_file(sample_rate, data, file.name)
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\runtime\lib\site-packages\gradio\processing_utils.py", line 206, in audio_to_file
data = convert_to_16_bit_wav(data)
File "D:\pre.zip\RVC20231006Nvidia\RVC1006Nvidia\runtime\lib\site-packages\gradio\processing_utils.py", line 219, in convert_to_16_bit_wav
if data.dtype in [np.float64, np.float32, np.float16]:
AttributeError: 'NoneType' object has no attribute 'dtype'

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with infer/lib/audio.py at load_audio and audio2, then follow the call from infer/modules/vc/modules.py in vc_single. Reproduce the failure with the reported audio input and inspect how the invalid MP3 decode error leads to the Gradio output path receiving None. The issue provides no input file or expected behavior, so the desired completed outcome is not defined.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
audio-video-rtc
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.