创建模块对象使用的是spk_model="cam++"方式报错了,请大佬们帮忙看看,感谢

Aperta
#2,546 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Ferma
Stack tecnologico
python

Direzione di ricerca

Start in funasr/auto/auto_model.py at the ClusterBackend construction shown in the traceback, then trace where ClusterBackend should be imported or defined. Check the speaker diarization initialization path and reproduce with the provided AutoModel arguments. Done means the model initializes without the NameError; this issue has had no comments for over a year, so confirm the failure still occurs.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

question

funasr版本:1.26.0
代码:
model = AutoModel(
model="paraformer-zh",
vad_model="fsmn-vad",
punc_model="ct-punc",
spk_model="cam++",
device="cpu",
quantize=True
)

报错:
Traceback (most recent call last):
File "C:\Users\admin\AppData\Roaming\JetBrains\IntelliJIdea2025.1\plugins\python-ce\helpers\pydev\pydevd.py", line 1570, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\admin\AppData\Roaming\JetBrains\IntelliJIdea2025.1\plugins\python-ce\helpers\pydev_pydev_imps_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "D:\Work Project\py-opencv\src\py-funasr.py", line 199, in
fsmn_vad()
File "D:\Work Project\py-opencv\src\py-funasr.py", line 15, in fsmn_vad
model = AutoModel(
^^^^^^^^^^
File "D:\WorkSpace\Python\Lib\site-packages\funasr\auto\auto_model.py", line 159, in init
self.cb_model = ClusterBackend(**cb_kwargs).to(kwargs["device"])
^^^^^^^^^^^^^^
NameError: name 'ClusterBackend' is not defined
python-BaseException

Lingua principale
Python
Stelle
21.2k
Fork
2.2k
Merge medio
5h 38m
PR unite (30g)
116

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di modelscope/FunASR

Tutte le issue di modelscope/FunASR

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.