OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized.

简介: OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized.

运行pytorch模型时,报错信息如下:

OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized.
OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade performance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by avoiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment variable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.


解决方法:


在train.py加入下列代码

os.environ["KMP_DUPLICATE_LIB_OK"] = "TRUE"


相关文章
|
10月前
|
C#
利用ICSharpCode.SharpZipLib.dll解析 出错:“Wrong Local header signature: 0xFF8”
## 分析原因 利用ICSharpCode.SharpZipLib.dll解析APK时,进入APK的AndroidXml获取时出现报错 ## 出错代码 ```csharp using (ICSharpCode.SharpZipLib.Zip.ZipInputStream zip = new ICSharpCode.SharpZipLib.Zip.ZipInputStream(File.OpenRead(path))) { using (var filestream = new FileStream(path, FileMode.Open, FileAccess.Read)) {
98 1
OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized.
OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized.
|
并行计算 Python
报错:OMP: Error #15: Initializing libomp.dylib, but found libiomp5.dylib already initialized.
报错:OMP: Error #15: Initializing libomp.dylib, but found libiomp5.dylib already initialized.
284 0
|
并行计算
解决Error #15: Initializing libiomp5.dylib, but found libomp.dylib already initialized.
解决Error #15: Initializing libiomp5.dylib, but found libomp.dylib already initialized.
340 0
|
网络安全 Python Windows
ImportError: DLL load failed while importing _ssl: 找不到指定的模块。
找到Anaconda3\pkgs\python-3.8.12-h900ac77_2_cpython\DLLs下的_ssl.pyd文件,查阅在该环境上安装的python版本号,下载python寻找对应的_ssl.pyd覆盖到上述目录中,即可解决问题。
781 0
编译OpenJDK11:configure: error: Target CPU mismatch. We are building for x86_64 but CL is for “版“; exp
编译OpenJDK11:configure: error: Target CPU mismatch. We are building for x86_64 but CL is for “版“; exp
151 0
cl.exe is unable to create an executable file. C compiler test failed.
cl.exe is unable to create an executable file. C compiler test failed.
179 0
|
开发工具
Unknown error: Unable to build: the file dx.jar was not loaded from the SDK folder!
Unknown error: Unable to build: the file dx.jar was not loaded from the SDK folder!
101 0
error while loading shared libraries: xxx.so.0:cannot open shared object file: No such file or
error while loading shared libraries: xxx.so.0:cannot open shared object file: No such file or
98 0
|
Perl
ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1
ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1
667 0