Hello folks! I am experiencing an OpenMP related ...
# modules
u
Hello folks! I am experiencing an OpenMP related error when running
GATK4_HAPLOTYPECALLER
module from nf-core. The error says,
Copy code
OMP: Error #15: Initializing libomp.so, but found unknown library 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://openmp.llvm.org/>
Anyone seen this one before? Any suggestion? I am using the nf-core module which is using a Seqera container now.
m
which setup do yu use?
docker, singularity?
u
Apptainer
x
@Usman I'm having exactly the same error. Did you find a solution for it?
u
Hi Yes, create a custom container with nomkl module.
👍 1
x
OK, thanks for the feedback. I will try the same. I'm surprised that this issue is not reported by more people.
m
I have never seen this error to be honest
Wich pipelines are you using?
u
This was in a custom pipeline.
x
I see it with the Sarek pipeline (3.6.1 and 3.8.1) when I use the parameter
--tools haplotypecaller
. But so far, I did not manage to reproduce it with
-profile test
k
Getting this with singularity and don't know the solution. Any ideas?
Sarek 3.6.1
x
I can avoid the error using by setting
KMP_DUPLICATE_LIB_OK=TRUE
in my container environment. I'm using something like this in my Nextflow configuration file:
Copy code
process {
  withName: 'GATK4_HAPLOTYPECALLER' {
    // Avoid bug related to double initialization of OpenMP library with GATK4_HAPLOTYPECALLER
    // Full error message is:
    // > OMP: Error #15: Initializing libomp.so, but found unknown library 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://openmp.llvm.org/>
    containerOptions = "--env KMP_DUPLICATE_LIB_OK='TRUE'"
  }
}
I don't know if it is safe to use this in this case, but I did not meet any issue so far.
k
That's what I'm using too but this should not be the intended solution.