Retrieval-based-Voice-Conversion-WebUI icon indicating copy to clipboard operation
Retrieval-based-Voice-Conversion-WebUI copied to clipboard

Training on Apple Silicon

Open eliasnassar opened this issue 2 years ago • 16 comments

Hey all,

I used my M1 MacBook Pro and trained a model with a dataset with .wav format that is 30 min long without slicing it, and I have some questions:

  1. Is it reasonable that it took more than 6 hours?
  2. Do slicing the dataset into < 10sec for every part, can make the training process faster?
  3. Is it that slow because RVC still doesn't support Apple Silicon, and the GPU is not being used?
  4. Are there any MPS updates coming to make training faster?

Hope some of you can help me with this 👯

eliasnassar avatar Jul 16 '23 13:07 eliasnassar

Hi eliasnassar,

I think I can answer your questions.

  1. Yes. It takes long time to train even for 10 min long, I left it overnight.
  2. Not sure, but slicing the dataset should be necessary.
  3. No, you can absolutely train a model using Apple Silicon. And the GPU is being used but some function not supported with MPS (Metal Performance Shaders), so it will use the CPU as a fallback :(
  4. I hope so. I saw some of the RVC developer use Macs as well :D

Naozumi520 avatar Jul 16 '23 16:07 Naozumi520

Hi eliasnassar,

After I finished using m2 max, I encountered the following error when executing python ./infer-web.py Traceback (most recent call last): File "/Users/guhaizhou/work/AI/RVConversion-WebUI/infer-web.py", line 21, in import faiss ModuleNotFoundError: No module named 'faiss'

It's obvious that I saw faiss cpu=>1.7.4 in requirements. txt

I really hope to receive your help. Thank you!!

guhaizhous avatar Jul 17 '23 15:07 guhaizhous

@eliasnassar Can you please help me to run on my MAC M1 Max. Shukran

Arslan007 avatar Oct 02 '23 04:10 Arslan007

@eliasnassar I can’t even get my to train on Mac m2. I had to use a windows gpu pc.

tobidev615 avatar Mar 16 '24 17:03 tobidev615

@Naozumi520 What particular part of the training pipeline isn't compatible with MPS?

Acelogic avatar Mar 29 '24 05:03 Acelogic

@Naozumi520 What particular part of the training pipeline isn't compatible with MPS?

Not sure, but you can find out with the line os.environ["PYTORCH_ENABLE_MPS_FALLBACK"] = "1" removed. This will stop using cpu as a fallback while training.

Naozumi520 avatar Mar 29 '24 16:03 Naozumi520

i have the same problem everything comes up with a big red ERROR when i boot up the live link.