request

#2
by Blane187 - opened

can you add file path input if in colab?

Can I be more specific?
I don't quite understand you

Or do you mean about the .ipynb file, you need to add it to the repository?

file path audio input for inference like this '/content/HRVC/rvc_models/audio.wav'

OK, I'll add that later

okay :)

Blane187 changed discussion status to closed
Politrees changed discussion status to open

Done! Except that google colab has blocked notebook, I'll have to look for workarounds :(

Politrees changed discussion status to closed

hey @Politrees i got eror when inference like this:

Traceback (most recent call last):
File "/usr/local/lib/python3.10/dist-packages/gradio/queueing.py", line 527, in process_events
response = await route_utils.call_process_api(
File "/usr/local/lib/python3.10/dist-packages/gradio/route_utils.py", line 270, in call_process_api
output = await app.get_blocks().process_api(
File "/usr/local/lib/python3.10/dist-packages/gradio/blocks.py", line 1847, in process_api
result = await self.call_function(
File "/usr/local/lib/python3.10/dist-packages/gradio/blocks.py", line 1433, in call_function
prediction = await anyio.to_thread.run_sync(
File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 33, in run_sync
return await get_asynclib().run_sync_in_worker_thread(
File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread
return await future
File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 807, in run
result = context.run(func, *args)
File "/usr/local/lib/python3.10/dist-packages/gradio/utils.py", line 805, in wrapper
response = f(*args, **kwargs)
File "/content/CoverGen/src/main.py", line 87, in song_cover_pipeline
voice_change(voice_model, orig_song_path, ai_cover_path, pitch_change, f0_method, index_rate,
File "/content/CoverGen/src/main.py", line 58, in voice_change
rvc_infer(rvc_index_path, index_rate, vocals_path, output_path, pitch_change, f0_method, cpt, version, net_g,
File "/content/CoverGen/src/rvc.py", line 168, in rvc_infer
audio_opt = vc.pipeline(
File "/content/CoverGen/src/vc_infer_pipeline.py", line 528, in pipeline
pitch, pitchf = self.get_f0(
File "/content/CoverGen/src/vc_infer_pipeline.py", line 308, in get_f0
f0 = self.get_f0_hybrid_computation(
File "/content/CoverGen/src/vc_infer_pipeline.py", line 172, in get_f0_hybrid_computation
methods_str = re.search("hybrid[(.+)]", methods_str)
NameError: name 're' is not defined
2024-07-19 06:03:49 | INFO | fairseq.tasks.hubert_pretraining | current directory is /content/CoverGen
2024-07-19 06:03:49 | INFO | fairseq.tasks.hubert_pretraining | HubertPretrainingTask Config {'_name': 'hubert_pretraining', 'data': 'metadata', 'fine_tuning': False, 'labels': ['km'], 'label_dir': 'label', 'label_rate': 50.0, 'sample_rate': 16000, 'normalize': False, 'enable_padding': False, 'max_keep_size': None, 'max_sample_size': 250000, 'min_sample_size': 32000, 'single_target': False, 'random_crop': True, 'pad_audio': False}
2024-07-19 06:03:49 | INFO | fairseq.models.hubert.hubert | HubertModel Config: {'_name': 'hubert', 'label_rate': 50.0, 'extractor_mode': default, 'encoder_layers': 12, 'encoder_embed_dim': 768, 'encoder_ffn_embed_dim': 3072, 'encoder_attention_heads': 12, 'activation_fn': gelu, 'layer_type': transformer, 'dropout': 0.1, 'attention_dropout': 0.1, 'activation_dropout': 0.0, 'encoder_layerdrop': 0.05, 'dropout_input': 0.1, 'dropout_features': 0.1, 'final_dim': 256, 'untie_final_proj': True, 'layer_norm_first': False, 'conv_feature_layers': '[(512,10,5)] + [(512,3,2)] * 4 + [(512,2,2)] * 2', 'conv_bias': False, 'logit_temp': 0.1, 'target_glu': False, 'feature_grad_mult': 0.1, 'mask_length': 10, 'mask_prob': 0.8, 'mask_selection': static, 'mask_other': 0.0, 'no_mask_overlap': False, 'mask_min_space': 1, 'mask_channel_length': 10, 'mask_channel_prob': 0.0, 'mask_channel_selection': static, 'mask_channel_other': 0.0, 'no_mask_channel_overlap': False, 'mask_channel_min_space': 1, 'conv_pos': 128, 'conv_pos_groups': 16, 'latent_temp': [2.0, 0.5, 0.999995], 'skip_masked': False, 'skip_nomask': False, 'checkpoint_activations': False, 'required_seq_len_multiple': 2, 'depthwise_conv_kernel_size': 31, 'attn_type': '', 'pos_enc_type': 'abs', 'fp16': False}
/usr/local/lib/python3.10/dist-packages/torch/nn/utils/weight_norm.py:28: UserWarning: torch.nn.utils.weight_norm is deprecated in favor of torch.nn.utils.parametrizations.weight_norm.
warnings.warn("torch.nn.utils.weight_norm is deprecated in favor of torch.nn.utils.parametrizations.weight_norm.")
gin_channels: 256 self.spk_embed_dim: 109

Traceback (most recent call last):
File "/usr/local/lib/python3.10/dist-packages/gradio/queueing.py", line 527, in process_events
response = await route_utils.call_process_api(
File "/usr/local/lib/python3.10/dist-packages/gradio/route_utils.py", line 270, in call_process_api
output = await app.get_blocks().process_api(
File "/usr/local/lib/python3.10/dist-packages/gradio/blocks.py", line 1847, in process_api
result = await self.call_function(
File "/usr/local/lib/python3.10/dist-packages/gradio/blocks.py", line 1433, in call_function
prediction = await anyio.to_thread.run_sync(
File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 33, in run_sync
return await get_asynclib().run_sync_in_worker_thread(
File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread
return await future
File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 807, in run
result = context.run(func, *args)
File "/usr/local/lib/python3.10/dist-packages/gradio/utils.py", line 805, in wrapper
response = f(*args, **kwargs)
File "/content/CoverGen/src/main.py", line 87, in song_cover_pipeline
voice_change(voice_model, orig_song_path, ai_cover_path, pitch_change, f0_method, index_rate,
File "/content/CoverGen/src/main.py", line 58, in voice_change
rvc_infer(rvc_index_path, index_rate, vocals_path, output_path, pitch_change, f0_method, cpt, version, net_g,
File "/content/CoverGen/src/rvc.py", line 168, in rvc_infer
audio_opt = vc.pipeline(
File "/content/CoverGen/src/vc_infer_pipeline.py", line 528, in pipeline
pitch, pitchf = self.get_f0(
File "/content/CoverGen/src/vc_infer_pipeline.py", line 304, in get_f0
gc.collect()
NameError: name 'gc' is not defined

why?

I forgot to write imports :)

Sign up or log in to comment