PlayVoice / whisper-vits-svc

Core Engine of Singing Voice Conversion & Singing Voice Clone
https://huggingface.co/spaces/maxmax20160403/sovits5.0
MIT License
2.62k stars 921 forks source link

Retrieval model error #155

Open dillfrescott opened 9 months ago

dillfrescott commented 9 months ago
Traceback (most recent call last):
  File "C:\Users\cross\Downloads\so-vits-svc-5.0\svc_inference.py", line 241, in <module>
    main(args)
  File "C:\Users\cross\Downloads\so-vits-svc-5.0\svc_inference.py", line 202, in main
    out_audio = svc_infer(model, retrieval, spk, pit, ppg, vec, hp, device)
  File "C:\Users\cross\Downloads\so-vits-svc-5.0\svc_inference.py", line 117, in svc_infer
    sub_ppg = retrieval.retriv_hubert(ppg[cut_s:cut_e, :])
  File "C:\Users\cross\Downloads\so-vits-svc-5.0\feature_retrieval\retrieval.py", line 43, in retriv_hubert
    np_vec = self._hubert_index.retriv(vec.numpy())
  File "C:\Users\cross\Downloads\so-vits-svc-5.0\feature_retrieval\index.py", line 59, in retriv
    scores, _, nearest_vectors = self._index.search_and_reconstruct(features, k=self._n_nearest)
  File "C:\Users\cross\miniconda3\envs\sovits\lib\site-packages\faiss\class_wrappers.py", line 378, in replacement_search_and_reconstruct
    assert d == self.d
AssertionError
xwang0415 commented 9 months ago

in svc_inference.py L117-L118: https://github.com/PlayVoice/so-vits-svc-5.0/blob/b61616d086ece100528de1c7d3b54a8daa01d88f/svc_inference.py#L117C18-L117C18 " sub_ppg = retrieval.retriv_hubert(ppg[cut_s:cut_e, :]) sub_vec = retrieval.retriv_whisper(vec[cut_s:cut_e, :]) "

be changed to: " sub_ppg = retrieval.retriv_whisper(ppg[cut_s:cut_e, :]) sub_vec = retrieval.retriv_hubert(vec[cut_s:cut_e, :]) " because ppg features are extracted from whisper,and vec features are extracted from hubert