prophesier / diff-svc

Singing Voice Conversion via diffusion model
GNU Affero General Public License v3.0
2.65k stars 806 forks source link

No module named 'utils' when running hubert_model.py #20

Open Zestea opened 2 years ago

Zestea commented 2 years ago

Before running the normal command for training, I tried running python python ./network/hubert/hubert_model.py from the diff-svc root directory. However, after running it, I just get the following issue:

Traceback (most recent call last):
  File "D:\Utau\diff-svc-main\network\hubert\hubert_model.py", line 13, in <module>
    from utils import hparams
ModuleNotFoundError: No module named 'utils'

Attempting to do a quick fix by copying hparam.py to the same folder as hubert_model.py and directly importing it from there gives me another issue:

Traceback (most recent call last):
  File "D:\Utau\diff-svc-main\network\hubert\hubert_model.py", line 266, in <module>
    hbt_model = hubert_soft(str(list(Path(hparams['hubert_path']).home().rglob('*.pt'))[0]))
TypeError: 'module' object is not subscriptable

Any idea what might be causing this and how I can fix it? If it helps, I'm running this on Windows 10.

prophesier commented 2 years ago

That part of the code is actually not under maintenance. I can't ensure it doesn't have any problem. You may try execute set PYTHONPATH=. at the root directory of this project.