2023-08-09 10:55:59 +03:00
|
|
|
from data.ModelSlot import BeatriceModelSlot
|
|
|
|
from mods.log_control import VoiceChangaerLogger
|
|
|
|
|
|
|
|
from voice_changer.utils.VoiceChangerModel import AudioInOut, VoiceChangerModel
|
|
|
|
from voice_changer.utils.VoiceChangerParams import VoiceChangerParams
|
|
|
|
|
|
|
|
|
|
|
|
logger = VoiceChangaerLogger.get_instance().getLogger()
|
|
|
|
|
|
|
|
|
|
|
|
class Beatrice(VoiceChangerModel):
|
2023-11-03 22:22:24 +03:00
|
|
|
def __init__(self, params: VoiceChangerParams, slotInfo: BeatriceModelSlot):
|
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def initialize(self):
|
2023-11-03 22:22:24 +03:00
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def setSamplingRate(self, inputSampleRate, outputSampleRate):
|
2023-11-03 22:22:24 +03:00
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def update_settings(self, key: str, val: int | float | str):
|
2023-11-03 22:22:24 +03:00
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def get_info(self):
|
2023-11-03 22:22:24 +03:00
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def get_processing_sampling_rate(self):
|
2023-11-03 22:22:24 +03:00
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def generate_input(
|
|
|
|
self,
|
|
|
|
newData: AudioInOut,
|
|
|
|
crossfadeSize: int,
|
|
|
|
solaSearchFrame: int = 0,
|
|
|
|
):
|
2023-11-03 22:22:24 +03:00
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def inference(self, receivedData: AudioInOut, crossfade_frame: int, sola_search_frame: int):
|
2023-11-03 22:22:24 +03:00
|
|
|
raise RuntimeError("not implemented")
|
2023-08-09 10:55:59 +03:00
|
|
|
|
|
|
|
def __del__(self):
|
|
|
|
del self.pipeline
|
|
|
|
|
|
|
|
def get_model_current(self):
|
|
|
|
return [
|
|
|
|
{
|
|
|
|
"key": "dstId",
|
|
|
|
"val": self.settings.dstId,
|
|
|
|
},
|
|
|
|
]
|