Skip to content

Remove dangerous workaround for multiple OpenMP libraries #32

@stefanv

Description

@stefanv

In engine.py we have:

# this needs to go in before importing torch
os.environ["KMP_DUPLICATE_LIB_OK"] = "True"

It looks like this arises from Intel MKL. The warning message states:

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/.

Not ideal. I presume this arises in Conda environments. It may be better to give advice on how to correctly set up an environment that avoids MKL and PyTorch with libiomp.

S/O suggests that it may look something like this:

conda install nomkl --channel conda-forge

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions