Update app.py
Browse files1234567891011128 unmodified lines212223242526272 unmodified lines303132333435361 unmodified line3839404142434445464748495051525354555657585960616263646566676869707172734 unmodified lines787980818283848586878889909192939495969798991001013 unmodified lines1051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421435 unmodified lines1491501511521531541551561571581591601611621631641651661671681691701711721731741751761771782 unmodified lines1811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272 unmodified lines230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552process.wait()progress(0.9, desc="Searching for model files...")# Search for model files in multiple possible locationspossible_paths = [log_dir / "weights",log_dir,self.rvc_dir / "weights" /import gradio as grimport osimport sysimport subprocess8 unmodified linesself.workspace = Path("./workspace")self.workspace.mkdir(exist_ok=True)self.setup_complete = Falsedef install_rvc(self, progress=gr.Progress()):"""Clone and setup official RVC repository"""try:2 unmodified linesif self.rvc_dir.exists():return "β RVC already installed!"# Clone official RVC reposubprocess.run(["git", "clone","https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI.git"1 unmodified lineprogress(0.3, desc="Installing dependencies...")# Install core dependencies manually (avoid conflicts)core_packages = ["torch","torchaudio","torchvision","numpy","scipy","librosa","soundfile","faiss-cpu","praat-parselmouth","pyworld","scikit-learn","numba","resampy","pydub","ffmpeg-python"]for pkg in core_packages:try:subprocess.run([sys.executable, "-m", "pip", "install", "-q", pkg], timeout=60)except:pass # Continue if one package failsprogress(0.6, desc="Downloading pretrained models...")# Download pretrained modelspretrained_dir = self.rvc_dir / "pretrained"pretrained_dir.mkdir(exist_ok=True)4 unmodified lines]for idx, (url, filename) in enumerate(models_to_download):progress(0.6 + (idx / len(models_to_download)) * 0.3,desc=f"Downloading {filename}...")output_path = pretrained_dir / filenameif not output_path.exists():try:# Try with wgetsubprocess.run(["wget", "-q", "-O", str(output_path), url], timeout=300)except:try:# Fallback to curlsubprocess.run(["curl", "-L", "-o", str(output_path), url], timeout=300)except:# Fallback to Python requestsimport requestsresponse = requests.get(url, stream=True, timeout=300)with open(output_path, 'wb') as f:3 unmodified linesself.setup_complete = Trueprogress(1.0, desc="Setup complete!")return """β RVC Installation Complete!π¦ Installed:- Official RVC codebase- Pre-trained models (f0G40k.pth, f0D40k.pth)- HuBERT base model- All dependenciesπ Ready to train real RVC models!"""except Exception as e:error_msg = str(e)return f"""β Installation failed: {error_msg}π§ Troubleshooting:1. **Try Manual Installation:**Run these commands in your Space terminal:```git clone https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI.gitpip install torch torchaudio numpy scipy librosa soundfile faiss-cpu```2. **Or use Google Colab (Recommended):**- Free GPU available- Faster training (hours instead of days)- Better compatibility3. **Alternative:** Use a simpler RVC training space or local installationWould you like a Google Colab notebook instead?"""def prepare_dataset(self, audio_files, model_name, progress=gr.Progress()):"""Prepare dataset in RVC format"""5 unmodified linestry:progress(0.1, desc="Creating dataset structure...")# Create RVC dataset structuredataset_path = self.rvc_dir / "dataset" / model_namedataset_path.mkdir(parents=True, exist_ok=True)progress(0.3, desc="Copying audio files...")# Copy audio filesfor idx, audio_file in enumerate(audio_files):dest = dataset_path / f"{idx:04d}_{Path(audio_file.name).name}"shutil.copy2(audio_file.name, dest)progress(0.3 + (idx / len(audio_files)) * 0.6,desc=f"Copied {idx+1}/{len(audio_files)} files")progress(1.0, desc="Dataset ready!")return f"""β Dataset Prepared!π Location: {dataset_path}π Files: {len(audio_files)}π€ Model Name: {model_name}β Ready for preprocessing!"""except Exception as e:return f"β Error: {str(e)}"2 unmodified lines"""Run RVC preprocessing"""try:progress(0.1, desc="Starting preprocessing...")dataset_path = self.rvc_dir / "dataset" / model_nameif not dataset_path.exists():return "β Dataset not found. Please prepare dataset first."# Run RVC preprocessing scriptpreprocess_script = self.rvc_dir / "infer" / "modules" / "train" / "preprocess.py"if not preprocess_script.exists():# Alternative pathpreprocess_script = self.rvc_dir / "trainset_preprocess_pipeline_print.py"progress(0.3, desc="Preprocessing audio...")cmd = [sys.executable,str(preprocess_script),str(dataset_path),str(sample_rate),"2" # Number of processes]result = subprocess.run(cmd, capture_output=True, text=True)progress(0.8, desc="Extracting features...")# Run feature extractionextract_script = self.rvc_dir / "infer" / "modules" / "train" / "extract_feature_print.py"if not extract_script.exists():extract_script = self.rvc_dir / "trainset_preprocess_pipeline_print.py"progress(1.0, desc="Preprocessing complete!")return f"""β Preprocessing Complete!π΅ Sample Rate: {sample_rate}Hzπ Features extractedπ Ready for training!Output: {result.stdout if result.stdout else 'Processing completed'}"""except Exception as e:return f"β Preprocessing failed: {str(e)}"2 unmodified lines"""Run actual RVC training"""try:progress(0.05, desc="Initializing training...")# Setup training pathslog_dir = self.rvc_dir / "logs" / model_namelog_dir.mkdir(parents=True, exist_ok=True)progress(0.1, desc="Starting RVC training...")# Training commandtrain_script = self.rvc_dir / "infer" / "modules" / "train" / "train.py"if not train_script.exists():train_script = self.rvc_dir / "train_nsf_sim_cache_sid_load_pretrain.py"cmd = [sys.executable,str(train_script),"-e", model_name,"-sr", str(sample_rate),"-f0", "1","-bs", str(batch_size),"-g", "0","-te", str(epochs),"-se", "10","-pg", str(self.rvc_dir / "pretrained" / "f0G40k.pth"),"-pd", str(self.rvc_dir / "pretrained" / "f0D40k.pth"),"-l", "0","-c", "0"]progress(0.2, desc=f"Training {model_name}...")# Run trainingprocess = subprocess.Popen(cmd,stdout=subprocess.PIPE,stderr=subprocess.PIPE,text=True)# Monitor training progressfor line in process.stdout:if "epoch" in line.lower():progress(0.2 + 0.6 * (int(line.split("epoch")[0]) / epochs),desc=f"Training: {line.strip()[:50]}")process.wait()progress(0.9, desc="Searching for model files...")# Search for model files in multiple possible locationspossible_paths = [log_dir / "weights",log_dir,self.rvc_dir / "weights" / model_name,self.rvc_dir / "logs" / model_name,self.rvc_dir / "trained_models" / model_name,]model_files = []for path in possible_paths:if path.exists():model_files.extend(list(path.glob("**/*.pth")))index_files = []for path in possible_paths:if path.exists():index_files.extend(list(path.glob("**/*.index")))if model_files or index_files:output_dir = self.workspace / model_nameoutput_dir.mkdir(exist_ok=True)if model_files:latest_model = max(model_files, key=lambda p: p.stat().st_mtime)shutil.copy2(latest_model, output_dir / f"{model_name}.pth")model_size = latest_model.stat().st_size / (1024*1024)else:model_size = 0if index_files:latest_index = max(index_files, key=lambda p: p.stat().st_mtime)shutil.copy2(latest_index, output_dir / latest_index.name)progress(1.0, desc="Training complete!")files_info = []if model_files:files_info.append(f"- {model_name}.pth ({model_size:.1f}MB)")if index_files:files_info.append(f"- {latest_index.name}")return f"""β Training Complete!π Model: {model_name}π Epochs: {epochs}βοΈ Batch Size: {batch_size}π΅ Sample Rate: {sample_rate}HzπΎ Model Files Found:{chr(10).join(files_info) if files_info else '- No files found'}π Location: {output_dir}π Ready to download!"""else:debug_info = []if log_dir.exists():debug_info.append(f"Log directory exists: {log_dir}")debug_info.append("Contents:")for item in log_dir.rglob("*"):debug_info.append(f" - {item.relative_to(log_dir)}")return f"""β οΈ Training completed but model files not found.π Searched in:{chr(10).join([f'- {p}' for p in possible_paths])}π Debug Info:{chr(10).join(debug_info) if debug_info else 'Log directory not found'}π‘ Possible issues:- Training may have failed silently- Model files saved to unexpected location- Check the RVC logs directory manually"""except Exception as e:return f"β Training failed: {str(e)}\n\nNote: Real RVC training requires significant resources. Consider using Google Colab with GPU."def package_model(self, model_name):"""Package model for download"""try:output_dir = self.workspace / model_nameif not output_dir.exists():# Try logs directoryoutput_dir = self.rvc_dir / "logs" / model_name / "weights"if not output_dir.exists():return None, "β Model not found"# Create zipzip_path = self.workspace / f"{model_name}_RVC.zip"with zipfile.ZipFile(zip_path, 'w', zipfile.ZIP_DEFLATED) as zipf:for file in output_dir.rglob("*"):if file.is_file() and (file.suffix in ['.pth', '.index', '.json']):zipf.write(file, file.name)return str(zip_path), f"β Model packaged: {zip_path.name}"except Exception as e:return None, f"β Error: {str(e)}"# Initialize trainertrainer = RealRVCTrainer()# Gradio Interfacewith gr.Blocks(title="Real RVC Training - HuggingFace") as demo:gr.Markdown("""# π€ Real RVC Model Training### Using Official RVC-Project Implementationβ οΈ **Important:** This uses the REAL RVC training code. Models will work on weights.gg!**Note:** Training on CPU will be slow. For faster training, use Google Colab with GPU.""")with gr.Tab("βοΈ Step 0: Install RVC"):gr.Markdown("""First, install the official RVC codebase and pretrained models.This will download:- RVC source code- Pretrained models (~200MB)- Required dependencies""")install_btn = gr.Button("π¦ Install RVC Components", variant="primary", size="lg")install_output = gr.Textbox(label="Installation Status", lines=10)install_btn.click(fn=trainer.install_rvc,outputs=install_output)with gr.Tab("π Step 1: Prepare Dataset"):gr.Markdown("""Upload your voice audio files**Requirements:**- 10-30 minutes recommended- WAV, MP3, FLAC formats- Clean, clear voice- Single speaker""")model_name_prep = gr.Textbox(label="Model Name",value="my_voice_model",placeholder="my_voice_model")audio_files = gr.File(label="Upload Audio Files",file_count="multiple",file_types=["audio"])prep_btn = gr.Button("π Prepare Dataset", variant="primary")prep_output = gr.Textbox(label="Status", lines=8)prep_btn.click(fn=trainer.prepare_dataset,inputs=[audio_files, model_name_prep],outputs=prep_output)with gr.Tab("π§ Step 2: Preprocess"):gr.Markdown("Preprocess audio and extract features")model_name_process = gr.Textbox(label="Model Name",value="my_voice_model")sample_rate_process = gr.Radio(choices=["40000", "48000"],value="40000",label="Sample Rate")process_btn = gr.Button("π§ Preprocess Data", variant="primary")process_output = gr.Textbox(label="Status", lines=8)process_btn.click(fn=trainer.preprocess_data,inputs=[model_name_process, sample_rate_process],outputs=process_output)with gr.Tab("π Step 3: Train Model"):gr.Markdown("""Train the RVC model with real neural network trainingβ οΈ **CPU Warning:** Training on CPU will take hours/days""")model_name_train = gr.Textbox(label="Model Name",value="my_voice_model")epochs_train = gr.Slider(minimum=10,maximum=500,value=100,step=10,label="Epochs (More = Better Quality)")batch_size_train = gr.Slider(minimum=1,maximum=16,value=4,step=1,label="Batch Size")sample_rate_train = gr.Radio(choices=["40000", "48000"],value="40000",label="Sample Rate")train_btn = gr.Button("π Start Real Training", variant="primary")train_output = gr.Textbox(label="Training Status", lines=15)train_btn.click(fn=trainer.train_model,inputs=[model_name_train, epochs_train, batch_size_train, sample_rate_train],outputs=train_output)with gr.Tab("π₯ Step 4: Download"):gr.Markdown("Download your trained RVC model")model_name_download = gr.Textbox(label="Model Name",value="my_voice_model")download_btn = gr.Button("π¦ Package Model", variant="primary")download_file = gr.File(label="Download")download_status = gr.Textbox(label="Status")download_btn.click(fn=trainer.package_model,inputs=model_name_download,outputs=[download_file, download_status])gr.Markdown("""---### π Resources- [RVC Project](https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI)- [Google Colab (Recommended for GPU)](https://colab.research.google.com/)- [Weights.gg](https://weights.gg/)### β οΈ Important Notes- This uses REAL RVC training - not simulation- Models will work on weights.gg and aicovergen- CPU training is VERY slow (hours to days)- **Recommended:** Use Google Colab with free GPU for 10-100x faster training- You'll need proper audio quality for good results""")if __name__ == "__main__":demo.launch()12348 unmodified lines131415161718192 unmodified lines2223242526271 unmodified line29303132333435363738394041424344454647484 unmodified lines5354555657585960616263646566673 unmodified lines717273747576777879805 unmodified lines86878889909192939495969798991001011022 unmodified lines1051061071081091101111121131141151161171181191201211221231242 unmodified lines127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269import gradio as grimport osimport sysimport subprocess8 unmodified linesself.workspace = Path("./workspace")self.workspace.mkdir(exist_ok=True)self.setup_complete = Falsedef install_rvc(self, progress=gr.Progress()):"""Clone and setup official RVC repository"""try:2 unmodified linesif self.rvc_dir.exists():return "β RVC already installed!"subprocess.run(["git", "clone","https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI.git"1 unmodified lineprogress(0.3, desc="Installing dependencies...")core_packages = ["torch", "torchaudio", "torchvision", "numpy", "scipy","librosa", "soundfile", "faiss-cpu", "praat-parselmouth","pyworld", "scikit-learn", "numba", "resampy", "pydub"]for pkg in core_packages:try:subprocess.run([sys.executable, "-m", "pip", "install", "-q", pkg], timeout=60)except:passprogress(0.6, desc="Downloading pretrained models...")pretrained_dir = self.rvc_dir / "pretrained"pretrained_dir.mkdir(exist_ok=True)4 unmodified lines]for idx, (url, filename) in enumerate(models_to_download):progress(0.6 + (idx / len(models_to_download)) * 0.3, desc=f"Downloading {filename}...")output_path = pretrained_dir / filenameif not output_path.exists():try:subprocess.run(["wget", "-q", "-O", str(output_path), url], timeout=300)except:try:subprocess.run(["curl", "-L", "-o", str(output_path), url], timeout=300)except:import requestsresponse = requests.get(url, stream=True, timeout=300)with open(output_path, 'wb') as f:3 unmodified linesself.setup_complete = Trueprogress(1.0, desc="Setup complete!")return "β RVC Installation Complete!\n\nπ¦ Installed:\n- Official RVC codebase\n- Pre-trained models\n- All dependencies\n\nπ Ready to train!"except Exception as e:return f"β Installation failed: {str(e)}\n\nπ§ Try manual installation or use Google Colab."def prepare_dataset(self, audio_files, model_name, progress=gr.Progress()):"""Prepare dataset in RVC format"""5 unmodified linestry:progress(0.1, desc="Creating dataset structure...")dataset_path = self.rvc_dir / "dataset" / model_namedataset_path.mkdir(parents=True, exist_ok=True)progress(0.3, desc="Copying audio files...")for idx, audio_file in enumerate(audio_files):dest = dataset_path / f"{idx:04d}_{Path(audio_file.name).name}"shutil.copy2(audio_file.name, dest)progress(0.3 + (idx / len(audio_files)) * 0.6, desc=f"Copied {idx+1}/{len(audio_files)} files")progress(1.0, desc="Dataset ready!")return f"β Dataset Prepared!\n\nπ Location: {dataset_path}\nπ Files: {len(audio_files)}\nπ€ Model: {model_name}\n\nβ Ready for preprocessing!"except Exception as e:return f"β Error: {str(e)}"2 unmodified lines"""Run RVC preprocessing"""try:progress(0.1, desc="Starting preprocessing...")dataset_path = self.rvc_dir / "dataset" / model_nameif not dataset_path.exists():return "β Dataset not found. Please prepare dataset first."preprocess_script = self.rvc_dir / "infer" / "modules" / "train" / "preprocess.py"if not preprocess_script.exists():preprocess_script = self.rvc_dir / "trainset_preprocess_pipeline_print.py"progress(0.3, desc="Preprocessing audio...")cmd = [sys.executable, str(preprocess_script), str(dataset_path), str(sample_rate), "2"]result = subprocess.run(cmd, capture_output=True, text=True)progress(1.0, desc="Preprocessing complete!")return f"β Preprocessing Complete!\n\nπ΅ Sample Rate: {sample_rate}Hz\nπ Features extracted\nπ Ready for training!"except Exception as e:return f"β Preprocessing failed: {str(e)}"2 unmodified lines"""Run actual RVC training"""try:progress(0.05, desc="Initializing training...")log_dir = self.rvc_dir / "logs" / model_namelog_dir.mkdir(parents=True, exist_ok=True)progress(0.1, desc="Starting RVC training...")train_script = self.rvc_dir / "infer" / "modules" / "train" / "train.py"if not train_script.exists():train_script = self.rvc_dir / "train_nsf_sim_cache_sid_load_pretrain.py"cmd = [sys.executable, str(train_script),"-e", model_name, "-sr", str(sample_rate),"-f0", "1", "-bs", str(batch_size),"-g", "0", "-te", str(epochs), "-se", "10","-pg", str(self.rvc_dir / "pretrained" / "f0G40k.pth"),"-pd", str(self.rvc_dir / "pretrained" / "f0D40k.pth"),"-l", "0", "-c", "0"]progress(0.2, desc=f"Training {model_name}...")process = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True)for line in process.stdout:if "epoch" in line.lower():progress(0.2 + 0.6, desc=f"Training: {line.strip()[:50]}")process.wait()progress(0.9, desc="Searching for model files...")possible_paths = [log_dir / "weights", log_dir,self.rvc_dir / "weights" / model_name,self.rvc_dir / "logs" / model_name]model_files = []index_files = []for path in possible_paths:if path.exists():model_files.extend(list(path.glob("**/*.pth")))index_files.extend(list(path.glob("**/*.index")))if model_files or index_files:output_dir = self.workspace / model_nameoutput_dir.mkdir(exist_ok=True)files_info = []if model_files:latest_model = max(model_files, key=lambda p: p.stat().st_mtime)shutil.copy2(latest_model, output_dir / f"{model_name}.pth")model_size = latest_model.stat().st_size / (1024*1024)files_info.append(f"- {model_name}.pth ({model_size:.1f}MB)")if index_files:latest_index = max(index_files, key=lambda p: p.stat().st_mtime)shutil.copy2(latest_index, output_dir / latest_index.name)files_info.append(f"- {latest_index.name}")progress(1.0, desc="Training complete!")return f"β Training Complete!\n\nπ Model: {model_name}\nπ Epochs: {epochs}\n\nπΎ Model Files:\n{chr(10).join(files_info)}\n\nπ Location: {output_dir}\n\nπ Ready to download!"else:debug_info = []if log_dir.exists():debug_info.append(f"Log dir: {log_dir}")for item in log_dir.rglob("*"):debug_info.append(f" - {item.relative_to(log_dir)}")return f"β οΈ Training completed but model files not found.\n\nπ Searched in:\n{chr(10).join([f'- {p}' for p in possible_paths])}\n\nπ Debug:\n{chr(10).join(debug_info)}"except Exception as e:return f"β Training failed: {str(e)}"def package_model(self, model_name):"""Package model for download"""try:output_dir = self.workspace / model_nameif not output_dir.exists():output_dir = self.rvc_dir / "logs" / model_name / "weights"if not output_dir.exists():return None, "β Model not found"zip_path = self.workspace / f"{model_name}_RVC.zip"with zipfile.ZipFile(zip_path, 'w', zipfile.ZIP_DEFLATED) as zipf:for file in output_dir.rglob("*"):if file.is_file() and (file.suffix in ['.pth', '.index', '.json']):zipf.write(file, file.name)return str(zip_path), f"β Model packaged: {zip_path.name}"except Exception as e:return None, f"β Error: {str(e)}"trainer = RealRVCTrainer()with gr.Blocks(title="Real RVC Training") as demo:gr.Markdown("# π€ Real RVC Model Training\n### Using Official RVC-Project Implementation\n\nβ οΈ Uses REAL RVC training. Models work on weights.gg!")with gr.Tab("βοΈ Step 0: Install RVC"):gr.Markdown("Install official RVC codebase and pretrained models (~200MB)")install_btn = gr.Button("π¦ Install RVC Components", variant="primary", size="lg")install_output = gr.Textbox(label="Installation Status", lines=10)install_btn.click(fn=trainer.install_rvc, outputs=install_output)with gr.Tab("π Step 1: Prepare Dataset"):gr.Markdown("Upload voice audio files (10-30 min recommended, WAV/MP3/FLAC)")model_name_prep = gr.Textbox(label="Model Name", value="my_voice_model")audio_files = gr.File(label="Upload Audio Files", file_count="multiple", file_types=["audio"])prep_btn = gr.Button("π Prepare Dataset", variant="primary")prep_output = gr.Textbox(label="Status", lines=8)prep_btn.click(fn=trainer.prepare_dataset, inputs=[audio_files, model_name_prep], outputs=prep_output)with gr.Tab("π§ Step 2: Preprocess"):gr.Markdown("Preprocess audio and extract features")model_name_process = gr.Textbox(label="Model Name", value="my_voice_model")sample_rate_process = gr.Radio(choices=["40000", "48000"], value="40000", label="Sample Rate")process_btn = gr.Button("π§ Preprocess Data", variant="primary")process_output = gr.Textbox(label="Status", lines=8)process_btn.click(fn=trainer.preprocess_data, inputs=[model_name_process, sample_rate_process], outputs=process_output)with gr.Tab("π Step 3: Train Model"):gr.Markdown("Train RVC model (β οΈ CPU training takes hours/days)")model_name_train = gr.Textbox(label="Model Name", value="my_voice_model")epochs_train = gr.Slider(minimum=10, maximum=500, value=100, step=10, label="Epochs")batch_size_train = gr.Slider(minimum=1, maximum=16, value=4, step=1, label="Batch Size")sample_rate_train = gr.Radio(choices=["40000", "48000"], value="40000", label="Sample Rate")train_btn = gr.Button("π Start Real Training", variant="primary")train_output = gr.Textbox(label="Training Status", lines=15)train_btn.click(fn=trainer.train_model, inputs=[model_name_train, epochs_train, batch_size_train, sample_rate_train], outputs=train_output)with gr.Tab("π₯ Step 4: Download"):gr.Markdown("Download your trained RVC model")model_name_download = gr.Textbox(label="Model Name", value="my_voice_model")download_btn = gr.Button("π¦ Package Model", variant="primary")download_file = gr.File(label="Download")download_status = gr.Textbox(label="Status")download_btn.click(fn=trainer.package_model, inputs=model_name_download, outputs=[download_file, download_status])gr.Markdown("---\n### π Resources\n- [RVC Project](https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI)\n- [Weights.gg](https://weights.gg/)\n\n### β οΈ Important\n- Uses REAL RVC training\n- Models work on weights.gg\n- CPU training is VERY slow\n- Recommended: Google Colab with GPU")if __name__ == "__main__":demo.launch()
app.py+53-336