Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CreateSeuratObject() error: Error in .local(x, na.rm, dims, ...) : object 'CRsparse_colSums' not found #8195

Closed
Dazcam opened this issue Dec 15, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@Dazcam
Copy link

Dazcam commented Dec 15, 2023

Hi there,

I've recently upgraded to Seurat 5 and I'm now receiving the above error when trying to run CreateSeuratObject() on a script that perviously ran without error. This script downloads publicly available data from a repository and runs the basic Seurat process. It worked previously when using Seurat versions 3 and 4.

However, this error also arises when running CreateSeuratObject() using the gene expression matrix and meta data extracted from the pbmc3k dataset:

library(Seurat)
library(SeuratData)

BiocManager::version()
#> [1] '3.18'

unloadNamespace('Azimuth', 'TFBSTools')

InstallData("pbmc3k")
data("pbmc3k")
#> Error: Please run UpdateSeuratObject on your object

pbmc3k <- UpdateSeuratObject(pbmc3k)
#> Validating object structure
#> Updating object slots
#> Ensuring keys are in the proper structure
#> Warning: Assay RNA changing from Assay to Assay
#> Ensuring keys are in the proper structure
#> Ensuring feature names don't have underscores or pipes
#> Updating slots in RNA
#> Validating object structure for Assay 'RNA'
#> Object representation is consistent with the most current Seurat version

pbmc3k
#> An object of class Seurat 
#> 13714 features across 2700 samples within 1 assay 
#> Active assay: RNA (13714 features, 0 variable features)
#> 2 layers present: counts, data

mat <- pbmc3k@assays$RNA@counts
meta <- pbmc3k@meta.data

test <- CreateSeuratObject(counts = mat, meta.data = meta)
#> Error in .local(x, na.rm, dims, ...) : 
#>  object 'CRsparse_colSums' not found

I have seen other posts recently on this issue and have tried to implement the following suggested 'solutions':

  • Upgraded Bioconductor manager to 3.18 (and updated packages accordingly)
  • Tried removing the Azimuth and TFBSTools packages using unloadNamespace()

I appreciate this may be an ongoing issue, but thought I'd start a new thread as the other threads imply this has been resolved.

Any help you could offer would be greatly appreciated.


Here is my sessionInfo():

R version 4.3.1 (2023-06-16)
Platform: x86_64-apple-darwin20 (64-bit)
Running under: macOS Big Sur 11.7.8

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib 
LAPACK: /Library/Frameworks/R.framework/Versions/4.3-x86_64/Resources/lib/libRlapack.dylib;  LAPACK version 3.11.0

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

time zone: Europe/London
tzcode source: internal

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] pbmc3k.SeuratData_3.1.4 SeuratData_0.2.2.9001   Seurat_5.0.1            SeuratObject_5.0.1      sp_2.1-2               
[6] shinyBS_0.61.1         

loaded via a namespace (and not attached):
  [1] fs_1.6.3                          ProtGenerics_1.34.0               matrixStats_1.2.0                
  [4] spatstat.sparse_3.0-3             bitops_1.0-7                      DirichletMultinomial_1.44.0      
  [7] lubridate_1.9.3                   TFBSTools_1.40.0                  httr_1.4.7                       
 [10] RColorBrewer_1.1-3                tools_4.3.1                       sctransform_0.4.1                
 [13] utf8_1.2.4                        R6_2.5.1                          DT_0.31                          
 [16] lazyeval_0.2.2                    uwot_0.1.16                       rhdf5filters_1.14.1              
 [19] withr_2.5.2                       scCustomize_2.0.1                 prettyunits_1.2.0                
 [22] gridExtra_2.3                     progressr_0.14.0                  cli_3.6.2                        
 [25] Biobase_2.62.0                    spatstat.explore_3.2-5            fastDummies_1.7.3                
 [28] EnsDb.Hsapiens.v86_2.99.0         shinyjs_2.1.0                     spatstat.data_3.0-3              
 [31] readr_2.1.4                       ggridges_0.5.5                    pbapply_1.7-2                    
 [34] Rsamtools_2.18.0                  R.utils_2.12.3                    parallelly_1.36.0                
 [37] BSgenome_1.70.1                   readxl_1.4.3                      rstudioapi_0.15.0                
 [40] RSQLite_2.3.4                     shape_1.4.6                       generics_0.1.3                   
 [43] BiocIO_1.12.0                     gtools_3.9.5                      ica_1.0-3                        
 [46] spatstat.random_3.2-2             googlesheets4_1.1.1               dplyr_1.1.4                      
 [49] GO.db_3.18.0                      Matrix_1.6-4                      ggbeeswarm_0.7.2                 
 [52] fansi_1.0.6                       S4Vectors_0.40.2                  abind_1.4-5                      
 [55] R.methodsS3_1.8.2                 lifecycle_1.0.4                   yaml_2.3.8                       
 [58] snakecase_0.11.1                  SummarizedExperiment_1.32.0       rhdf5_2.46.1                     
 [61] SparseArray_1.2.2                 BiocFileCache_2.10.1              Rtsne_0.17                       
 [64] paletteer_1.5.0                   grid_4.3.1                        blob_1.2.4                       
 [67] promises_1.2.1                    shinydashboard_0.7.2              crayon_1.5.2                     
 [70] Require_0.3.1                     miniUI_0.1.1.1                    lattice_0.22-5                   
 [73] cowplot_1.1.2                     GenomicFeatures_1.54.1            annotate_1.80.0                  
 [76] KEGGREST_1.42.0                   knitr_1.45                        pillar_1.9.0                     
 [79] GenomicRanges_1.54.1              rjson_0.2.21                      future.apply_1.11.0              
 [82] codetools_0.2-19                  fastmatch_1.1-4                   leiden_0.4.3.1                   
 [85] glue_1.6.2                        data.table_1.14.10                vctrs_0.6.5                      
 [88] png_0.1-8                         spam_2.10-0                       cellranger_1.1.0                 
 [91] gtable_0.3.4                      poweRlaw_0.70.6                   rematch2_2.1.2                   
 [94] cachem_1.0.8                      xfun_0.41                         Signac_1.12.0                    
 [97] S4Arrays_1.2.0                    mime_0.12                         pracma_2.4.4                     
[100] survival_3.5-7                    gargle_1.5.2                      RcppRoll_0.3.0                   
[103] ellipsis_0.3.2                    fitdistrplus_1.1-11               ROCR_1.0-11                      
[106] nlme_3.1-164                      bit64_4.0.5                       progress_1.2.3                   
[109] filelock_1.0.3                    RcppAnnoy_0.0.21                  GenomeInfoDb_1.38.2              
[112] irlba_2.3.5.1                     vipor_0.4.5                       KernSmooth_2.23-22               
[115] SeuratDisk_0.0.0.9021             colorspace_2.1-0                  seqLogo_1.68.0                   
[118] BiocGenerics_0.48.1               DBI_1.1.3                         ggrastr_1.0.2                    
[121] tidyselect_1.2.0                  bit_4.0.5                         compiler_4.3.1                   
[124] curl_5.2.0                        hdf5r_1.3.8                       xml2_1.3.6                       
[127] DelayedArray_0.28.0               plotly_4.10.3                     rtracklayer_1.62.0               
[130] scales_1.3.0                      caTools_1.18.2                    lmtest_0.9-40                    
[133] rappdirs_0.3.3                    stringr_1.5.1                     digest_0.6.33                    
[136] goftest_1.2-3                     presto_1.0.0                      spatstat.utils_3.0-4             
[139] rmarkdown_2.25                    XVector_0.42.0                    htmltools_0.5.7                  
[142] pkgconfig_2.0.3                   MatrixGenerics_1.14.0             dbplyr_2.4.0                     
[145] fastmap_1.1.1                     ensembldb_2.26.0                  GlobalOptions_0.1.2              
[148] rlang_1.1.2                       htmlwidgets_1.6.4                 shiny_1.8.0                      
[151] zoo_1.8-12                        jsonlite_1.8.8                    BiocParallel_1.36.0              
[154] R.oo_1.25.0                       RCurl_1.98-1.13                   magrittr_2.0.3                   
[157] GenomeInfoDbData_1.2.11           dotCall64_1.1-1                   patchwork_1.1.3                  
[160] Rhdf5lib_1.24.1                   munsell_0.5.0                     Rcpp_1.0.11                      
[163] reticulate_1.34.0                 stringi_1.8.3                     zlibbioc_1.48.0                  
[166] MASS_7.3-60                       plyr_1.8.9                        parallel_4.3.1                   
[169] listenv_0.9.0                     ggrepel_0.9.4                     forcats_1.0.0                    
[172] deldir_2.0-2                      CNEr_1.38.0                       Biostrings_2.70.1                
[175] splines_4.3.1                     tensor_1.5                        circlize_0.4.15                  
[178] hms_1.1.3                         BSgenome.Hsapiens.UCSC.hg38_1.4.5 igraph_1.6.0                     
[181] spatstat.geom_3.2-7               RcppHNSW_0.5.0                    reshape2_1.4.4                   
[184] biomaRt_2.58.0                    stats4_4.3.1                      TFMPvalue_0.0.9                  
[187] XML_3.99-0.16                     evaluate_0.23                     ggprism_1.0.4                    
[190] JASPAR2020_0.99.10                tzdb_0.4.0                        httpuv_1.6.13                    
[193] RANN_2.6.1                        tidyr_1.3.0                       purrr_1.0.2                      
[196] polyclip_1.10-6                   future_1.33.0                     scattermore_1.2                  
[199] ggplot2_3.4.4                     janitor_2.2.0                     xtable_1.8-4                     
[202] restfulr_0.0.15                   AnnotationFilter_1.26.0           RSpectra_0.16-1                  
[205] later_1.3.2                       googledrive_2.1.1                 viridisLite_0.4.2                
[208] tibble_3.2.1                      Azimuth_0.5.0                     beeswarm_0.4.0                   
[211] memoise_2.0.1                     AnnotationDbi_1.64.1              GenomicAlignments_1.38.0         
[214] IRanges_2.36.0                    cluster_2.1.6                     timechange_0.2.0   
@Dazcam Dazcam added the bug Something isn't working label Dec 15, 2023
@dcollins15
Copy link
Contributor

A solution is available here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants