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

AttributeError: 'RVC' object has no attribute 'tgt_sr'

Open
#2,191 3 comments 1 reaction 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

Program just freezes and this comes up on CMD

C:\Users\Casper\Desktop\RVC1006AMD_Intel1>runtime\python.exe gui_v1.py --pycmd runtime\python.exe --dml
2024-07-14 23:31:54 | INFO | faiss.loader | Loading faiss.
2024-07-14 23:31:54 | INFO | faiss.loader | Successfully loaded faiss.
2024-07-14 23:31:55 | INFO | configs.config | No supported Nvidia GPU found
overwrite preprocess and configs.json
2024-07-14 23:31:56 | INFO | configs.config | Use DirectML instead
is_half:False, device:privateuseone:0
Input device: 4:VoiceMeeter Output (VB-Audio Vo (MME)
Output device: 19:Hoparlör (Realtek High Definition Audio) (Windows DirectSound)
cuda_is_available: False
Traceback (most recent call last):
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\tools\rvc_for_realtime.py", line 102, in __init__
    hubert_model = hubert_model.to(self.device)
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\runtime\lib\site-packages\torch\nn\modules\module.py", line 1145, in to
    return self._apply(convert)
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\runtime\lib\site-packages\torch\nn\modules\module.py", line 797, in _apply
    module._apply(fn)
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\runtime\lib\site-packages\torch\nn\modules\module.py", line 797, in _apply
    module._apply(fn)
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\runtime\lib\site-packages\torch\nn\modules\module.py", line 797, in _apply
    module._apply(fn)
  [Previous line repeated 1 more time]
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\runtime\lib\site-packages\torch\nn\modules\module.py", line 820, in _apply
    param_applied = fn(param)
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\runtime\lib\site-packages\torch\nn\modules\module.py", line 1143, in convert
    return t.to(device, dtype if t.is_floating_point() or t.is_complex() else None, non_blocking)
RuntimeError

Traceback (most recent call last):
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\gui_v1.py", line 954, in <module>
    gui = GUI()
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\gui_v1.py", line 134, in __init__
    self.launcher()
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\gui_v1.py", line 459, in launcher
    self.event_handler()
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\gui_v1.py", line 490, in event_handler
    self.start_vc()
  File "C:\Users\Casper\Desktop\RVC1006AMD_Intel1\gui_v1.py", line 636, in start_vc
    self.gui_config.samplerate = self.rvc.tgt_sr if self.gui_config.sr_type == "sr_model" else self.get_device_samplerate()
AttributeError: 'RVC' object has no attribute 'tgt_sr'

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 tools/rvc_for_realtime.py around its initialization and gui_v1.py in start_vc, using the provided DirectML startup path to reproduce the failure. Trace why initialization stops before tgt_sr is available; done means the realtime GUI starts without the AttributeError.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.