OpenVoice
OpenVoice copied to clipboard
CPU support for voice tone extraction
By default OpenVoice uses CUDA for voice tone extraction which is a pain in the ass for CPU runtimes. i can modify the SRC of the se_extractor.py to use a CUDA/CPU switcher to check for drivers but again its pain in the ass to modify the internal dependency code everytime when i start a fresh new codebase. it will be good if yall can add that to the repo so that when i do a new fresh install i dont need to modify the src everytime!
thank you!
model = None
def split_audio_whisper(audio_path, audio_name, target_dir='processed'):
global model
if model is None:
model = WhisperModel(model_size, device="cuda", compute_type="float16")
just add a model argument to the function so that we can choose cpu or gpu with different float values for ie my instance uses float32...