Skip to content

'tuple' object has no attribute 'dtype' #42

Description

@Yakator

I have been trying to fix this error for a while, with no effectiveness. I have seen the other posts in here, none of them worked for me. This error occurs when I use the API mode of the library (I don't get any errors when I'm using the Python Module), I get the error:

2025-11-30 21:16:02.796 | INFO     | rvc_python.api:rvc_convert:40 - Received request to convert audio
2025-11-30 21:16:02 | WARNING | rvc_python.modules.vc.modules | Traceback (most recent call last):
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\modules\vc\modules.py", line 184, in vc_single
    audio_opt = self.pipeline.pipeline(
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\modules\vc\pipeline.py", line 359, in pipeline
    pitch, pitchf = self.get_f0(
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\modules\vc\pipeline.py", line 157, in get_f0
    f0 = self.model_rmvpe.infer_from_audio(x, thred=0.03)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\lib\rmvpe.py", line 605, in infer_from_audio
    hidden = self.mel2hidden(mel)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\lib\rmvpe.py", line 584, in mel2hidden
    hidden = self.model(mel)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl
    return forward_call(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\lib\rmvpe.py", line 409, in forward
    x = self.cnn(self.unet(mel)).transpose(1, 2).flatten(-2)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl
    return forward_call(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\lib\rmvpe.py", line 367, in forward
    x, concat_tensors = self.encoder(x)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl
    return forward_call(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\rvc_python\lib\rmvpe.py", line 244, in forward
    x = self.bn(x)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1518, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\module.py", line 1527, in _call_impl
    return forward_call(*args, **kwargs)
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\modules\batchnorm.py", line 171, in forward
    return F.batch_norm(
  File "E:\AI\AI bot\RVCvenv\lib\site-packages\torch\nn\functional.py", line 2478, in batch_norm
    return torch.batch_norm(
RuntimeError: "batch_norm" not implemented for 'Half'

2025-11-30 21:16:02.984 | ERROR    | rvc_python.api:rvc_convert:57 - 'tuple' object has no attribute 'dtype'
INFO:     127.0.0.1:60576 - "POST /convert HTTP/1.1" 500 Internal Server Error

I'm a beginner programmer, so I don't know much about this stuff, so I would be thankful if someone could help me on this please. By the way, I don't if this is important, but I'm using Python 3.10.7 and torch 2.1.1+cu118, on Windows 10.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions