python – Fix “OMP: Error #15: Initializing libomp.dylib, but found libiomp5.dylib already initialized.” in NON conda env

I know there is a ton of threads asking this question. However, they all deal with conda envs and state conda packages conflicting libomps and the solution would be to install the no-mkl meta package.

I do not use conda but a “normal” venv created by Python3.9 (either from python.org installer or from brew) and install packages via pip.

Why would this also happen without conda and is there a way to solve it?

It happens when using faster-whisper in a x86_64 venv, but not an arm64 venv.

Read more here: Source link