I am trying to load Seurat in RStudio to analyse sc-RNAseq data.
I run the following commands:
install.packages('BiocManager')
BiocManager::install('multtest')
install.packages('Seurat')
library(Seurat)
And when library(Seurat) is run, the following error occurs:
R Session aborted. R encountered a fatal error. The session was terminated
I have tried completely uninstalling R and Rstudio and all their associated files, reinstalling and running the code again, but it still crashes, every time.
I have also tried installing an older version of Rstudio and I still have the same issues.
I don't have any issues with other packages and can use the same data to do other analysis- so it seems like Seurat maybe the issue.
R version 3.6.3 (2020-02-29) -- "Holding the Windsock"
RStudio version 1.2.5033
MacOSX Catalina
Does anyone know what could be the cause of the issue?
Thanks!
I have this same problem! Please help!!!
I am having the same problem and would appreciate any troubleshooting assistance.
I have run Seurat successfully before no problem (earlier this month) and now when I go to load the package it causes RStudio to crash.
Same issue.
Same R version
RStudio Version 1.1.423
macOS Mojave (Version 10.14.6)
Can you provide the output of sessionInfo() from before you try loading Seurat? Do you get the error when you try loading Seurat from R in the terminal or just R in RStudio?
Below is the additional information requested:
Seurat will not load from the terminal as well as RStudio.
R Studio Version: 1.2.5033
sessionInfo()
R version 3.5.0 (2018-04-23)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS High Sierra 10.13.6
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.5/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_3.5.0 tools_3.5.0
Hi @mojaveazure
This is the output when I run sessionInfo()
sessionInfo()
R version 3.6.3 (2020-02-29)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Catalina 10.15.3
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
locale:
[1] en_AU.UTF-8/en_AU.UTF-8/en_AU.UTF-8/C/en_AU.UTF-8/en_AU.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] BiocManager_1.30.10 compiler_3.6.3 tools_3.6.3
Seurat will not load in either RStudio or from the Terminal.
When I try to run it through the terminal, this is the error that I get:
library(Seurat)
INTEL MKL ERROR: dlopen(/Users/hannahlaw/Library/r-miniconda/envs/r-reticulate/lib/libmkl_intel_thread.dylib, 9): Library not loaded: @rpath/libiomp5.dylib
Referenced from: /Users/hannahlaw/Library/r-miniconda/envs/r-reticulate/lib/libmkl_intel_thread.dylib
Reason: image not found.
Intel MKL FATAL ERROR: Cannot load libmkl_intel_thread.dylib.
Thank you!
Install via BiocManager::install(), when library it, Rstudio crashed. Reoccurred.
R version 3.6.2 (2019-12-12)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Catalina 10.15.4
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] BiocManager_1.30.10 compiler_3.6.2 tools_3.6.2
sessionInfo()
R version 3.6.3 (2020-02-29)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Mojave 10.14.6
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
Random number generation:
RNG: Mersenne-Twister
Normal: Inversion
Sample: Rounding
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets
[6] methods base
loaded via a namespace (and not attached):
[1] compiler_3.6.3 tools_3.6.3 yaml_2.2.1
When I ran it in the terminal, the following error was produced:
library(Seurat)
INTEL MKL ERROR: dlopen(/Users/jxiong/Library/r-miniconda/envs/r-reticulate/lib/libmkl_intel_thread.dylib, 9): Library not loaded: @rpath/libiomp5.dylib
Referenced from: /Users/jxiong/Library/r-miniconda/envs/r-reticulate/lib/libmkl_intel_thread.dylib
Reason: image not found.
Intel MKL FATAL ERROR: Cannot load libmkl_intel_thread.dylib.
same problem here: I could still run Seurat normally yesterday, today both running library(Seurat) from RStudio and terminal leads to crashing of R with 'fatal error encountered'. I am not aware that anything changed in my software status between yesterday and today.
I have tried re-start/updating computer software/re-installing Seurat, all didn't work.
> sessionInfo()
R version 3.6.2 (2019-12-12)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Mojave 10.14.6
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_3.6.2 tools_3.6.2 yaml_2.2.1
Any clue for this fatal error??
@helpmewithr, it seems as though your Conda installation is messing with your R installation. I would suggest purging Conda from your system. We've had issues before where Conda interferes with R/Seurat, so we strongly recommend that you not use Conda.
@woodjos8, @mimisikai, @junhaobearxiong, and @ilonliu since you all have the same error as @helpmewithr, I would recommend checking for Conda on your systems as well and removing if present. If you do not have Conda on your system and you are still getting this error, please open a new issue.
I removed the directory ~/Library/r-miniconda and Seurat loaded without problems.
I use another laptop, macOS, which never been have Seurat and minoconda, to install Seurat.
It shows : no non-system installation of python could be found. Would you like to download and install Miniconda?
I'm confused. If Python and Miniconda are required for Seurat, why we have to remove Conda?
BTW, both laptops don't have Miniconda, but both have PyChat.
Update: When the "new" laptop installing MiniConda, I can load Seurat library now. It's so conflict to what your tip. I guess it may not about miniconda, at least not the case in my laptop.
I do not have Miniconda... I am using R 3.6.3 on MacOS Catalina v 10.15.4 and every time I try to load the library for Seurat as of today it is crashing with the same error "R Session aborted. R encountered a fatal error. The session was terminated". I've been using Seurat almost every day, most recently yesterday, I am not sure why it is all of a sudden no longer working.
I have uninstalled/reinstalled Seurat, uninstalled other R packages I have installed, uninstalled/reinstalled R, updated R studio, restarted my laptop, and everything else under the sun I can think of.
If anyone has a solution I would be grateful to know - my issue cannot be due to miniconda as I don't have miniconda.
Hi all, I had the same problem when I loaded Seurat. I also used macOS Catalina and R 3.6.2.
I tried to delete ~/Library/r-miniconda but it didn't work.
One possible solution is here (https://community.rstudio.com/t/r-studio-crashes-when-loading-seurat-package/57931/7)
Based on DB_science, I tried the following and it worked!
Try:
remove.packages('reticulate')
remove.packages('Seurat')
install.packages('Seurat')
library(Seurat)
and wherever it asks if you wanna compile from source say no
If it doesn't work, how about first delete ~/Library/r-miniconda and then try the above steps?
Also attach my session information:
sessionInfo()
R version 3.6.2 (2019-12-12)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Catalina 10.15.4
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] dplyr_0.8.5
Ok, so i just had the same problem. Turns out, I needed to remove r-miniconda, then try to install.packages("Seurat") again.
Coming back to this issue. I really need the r-miniconda environment because I want to run pythn keras on the new bone marrow data (bmcite) that come with seurat v4. But when I install it using reticulate::install_miniconda(), I cannot load Seurat anymore. Please help!!
Hi all,
I am facing the same problem, I tried all the mentioned solutions and none have worked for me so far. BTW, I don't have r-miniconda on my computer. Here is the error I got:
> library(Seurat)
OMP: Error #15: Initializing libomp.dylib, but found libomp.dylib 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/
Abort trap: 6
> sessionInfo()
R version 3.6.3 (2020-02-29)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Catalina 10.15.6
Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRblas.0.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_3.6.3
Could someone please help?
Most helpful comment
I removed the directory
~/Library/r-minicondaand Seurat loaded without problems.