WIP: Diffusion svc refining: auto speaker id detect
This commit is contained in:
parent
b9429c7655
commit
37468e3cc9
@ -115,6 +115,8 @@ class DiffusionSVCModelSlot(ModelSlot):
|
|||||||
defaultKstep: int = 20
|
defaultKstep: int = 20
|
||||||
defaultSpeedup: int = 10
|
defaultSpeedup: int = 10
|
||||||
kStepMax: int = 100
|
kStepMax: int = 100
|
||||||
|
nLayers: int = 20
|
||||||
|
nnLayers: int = 20
|
||||||
speakers: dict = field(default_factory=lambda: {1: "user"})
|
speakers: dict = field(default_factory=lambda: {1: "user"})
|
||||||
embedder: EmbedderType = "hubert_base"
|
embedder: EmbedderType = "hubert_base"
|
||||||
samplingRate: int = 44100
|
samplingRate: int = 44100
|
||||||
|
@ -33,8 +33,10 @@ class DiffusionSVCModelSlotGenerator(ModelSlotGenerator):
|
|||||||
def _setInfoByPytorch(cls, slot: DiffusionSVCModelSlot):
|
def _setInfoByPytorch(cls, slot: DiffusionSVCModelSlot):
|
||||||
diff_model, diff_args, naive_model, naive_args, vocoder = load_model_vocoder_from_combo(slot.modelFile, device="cpu")
|
diff_model, diff_args, naive_model, naive_args, vocoder = load_model_vocoder_from_combo(slot.modelFile, device="cpu")
|
||||||
slot.kStepMax = diff_args.model.k_step_max
|
slot.kStepMax = diff_args.model.k_step_max
|
||||||
slot.n_layers = diff_args.model.n_layers
|
slot.nLayers = diff_args.model.n_layers
|
||||||
|
slot.nnLayers = naive_args.model.n_layers
|
||||||
|
diff_args.model.n_spk
|
||||||
|
slot.speakers = {(x+1): f"user{x+1}" for x in range(diff_args.model.n_spk)}
|
||||||
return slot
|
return slot
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
|
Loading…
x
Reference in New Issue
Block a user