RVC-Project / RVC-Project/Retrieval-based-Voice-Conversion-WebUI

Macos15 Sequoia 关于NotImplementedError: Output channels > 65536 not supported at the MPS device.的问题

Open
#2,393 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
38.4k
Forks
5.3k
PR merge metrics
No merged PRs in 30d

Description

主要的问题是:
NotImplementedError: Output channels > 65536 not supported at the MPS device. As a temporary fix, you can set the environment variable PYTORCH_ENABLE_MPS_FALLBACK=1 to use the CPU as a fallback for this op. WARNING: this will be slower than running natively on MPS.
(个人感觉)一般来说Output channels 应该不会大于65536,是不是因为macos15最新的系统问题或者程序内部跟macos15不兼容的问题?

以下是报错问题终端日志:
2024-11-26 23:12:12 | INFO | configs.config | No supported Nvidia GPU found
2024-11-26 23:12:12 | INFO | configs.config | overwrite v1/32k.json
2024-11-26 23:12:12 | INFO | configs.config | overwrite v1/40k.json
2024-11-26 23:12:12 | INFO | configs.config | overwrite v1/48k.json
2024-11-26 23:12:12 | INFO | configs.config | overwrite v2/48k.json
2024-11-26 23:12:12 | INFO | configs.config | overwrite v2/32k.json
2024-11-26 23:12:12 | INFO | configs.config | overwrite preprocess_per to 3
2024-11-26 23:12:12 | INFO | configs.config | Use mps instead
2024-11-26 23:12:12 | INFO | configs.config | Half-precision floating-point: False, device: mps
/opt/miniconda3/lib/python3.9/site-packages/gradio_client/documentation.py:106: UserWarning: Could not get documentation group for <class 'gradio.mix.Parallel'>: No known documentation group for module 'gradio.mix'
warnings.warn(f"Could not get documentation group for {cls}: {exc}")
/opt/miniconda3/lib/python3.9/site-packages/gradio_client/documentation.py:106: UserWarning: Could not get documentation group for <class 'gradio.mix.Series'>: No known documentation group for module 'gradio.mix'
warnings.warn(f"Could not get documentation group for {cls}: {exc}")
2024-11-26 23:12:12 | INFO | main | Use Language: en_US

Thanks for being a Gradio user! If you have questions or feedback, please join our Discord server and chat with us: https://discord.gg/feTf9x3ZSB
Running on local URL: http://0.0.0.0:7865
2024-11-26 23:12:17 | INFO | infer.modules.vc.modules | Get sid: DL.pth
2024-11-26 23:12:17 | INFO | infer.modules.vc.modules | Loading: assets/weights/DL.pth
2024-11-26 23:12:17 | INFO | infer.modules.vc.modules | Select index:
2024-11-26 23:12:25 | INFO | fairseq.tasks.hubert_pretraining | current directory is /Users/wong/Documents/RVC/Retrieval-based-Voice-Conversion-WebUI
2024-11-26 23:12:25 | 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-11-26 23:12:25 | 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}
2024-11-26 23:12:26 | INFO | infer.modules.vc.pipeline | Loading rmvpe model,assets/rmvpe/rmvpe.pt
2024-11-26 23:12:28 | WARNING | infer.modules.vc.modules | Traceback (most recent call last):
File "/Users/wong/Documents/RVC/Retrieval-based-Voice-Conversion-WebUI/infer/modules/vc/modules.py", line 188, in vc_single
audio_opt = self.pipeline.pipeline(
File "/Users/wong/Documents/RVC/Retrieval-based-Voice-Conversion-WebUI/infer/modules/vc/pipeline.py", line 410, in pipeline
self.vc(
File "/Users/wong/Documents/RVC/Retrieval-based-Voice-Conversion-WebUI/infer/modules/vc/pipeline.py", line 219, in vc
logits = model.extract_features(**inputs)
File "/opt/miniconda3/lib/python3.9/site-packages/fairseq/models/hubert/hubert.py", line 535, in extract_features
res = self.forward(
File "/opt/miniconda3/lib/python3.9/site-packages/fairseq/models/hubert/hubert.py", line 437, in forward
features = self.forward_features(source)
File "/opt/miniconda3/lib/python3.9/site-packages/fairseq/models/hubert/hubert.py", line 392, in forward_features
features = self.feature_extractor(source)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1736, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1747, in _call_impl
return forward_call(*args, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/fairseq/models/wav2vec/wav2vec2.py", line 895, in forward
x = conv(x)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1736, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1747, in _call_impl
return forward_call(*args, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/container.py", line 250, in forward
input = module(input)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1736, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1747, in _call_impl
return forward_call(*args, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/conv.py", line 375, in forward
return self._conv_forward(input, self.weight, self.bias)
File "/opt/miniconda3/lib/python3.9/site-packages/torch/nn/modules/conv.py", line 370, in _conv_forward
return F.conv1d(
NotImplementedError: Output channels > 65536 not supported at the MPS device. As a temporary fix, you can set the environment variable PYTORCH_ENABLE_MPS_FALLBACK=1 to use the CPU as a fallback for this op. WARNING: this will be slower than running natively on MPS.

Traceback (most recent call last):
File "/opt/miniconda3/lib/python3.9/site-packages/gradio/routes.py", line 437, in run_predict
output = await app.get_blocks().process_api(
File "/opt/miniconda3/lib/python3.9/site-packages/gradio/blocks.py", line 1349, in process_api
data = self.postprocess_data(fn_index, result["prediction"], state)
File "/opt/miniconda3/lib/python3.9/site-packages/gradio/blocks.py", line 1283, in postprocess_data
prediction_value = block.postprocess(prediction_value)
File "/opt/miniconda3/lib/python3.9/site-packages/gradio/components.py", line 2586, in postprocess
file_path = self.audio_to_temp_file(
File "/opt/miniconda3/lib/python3.9/site-packages/gradio/components.py", line 360, in audio_to_temp_file
temp_dir = Path(dir) / self.hash_bytes(data.tobytes())
AttributeError: 'NoneType' object has no attribute 'tobytes'

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with infer/modules/vc/pipeline.py around line 219 and infer/modules/vc/modules.py around line 188, then trace the fairseq HuBERT convolution path shown in the traceback. Reproduce the failure on macOS 15 with the MPS device and compare it with PYTORCH_ENABLE_MPS_FALLBACK=1; done means identifying the compatibility cause and documenting or resolving the supported behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, python, pytorch
Domain
audio-video-rtc, machine-learning, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.