drieslab / Giotto

Spatial omics analysis toolbox
https://drieslab.github.io/Giotto_website/
Other
258 stars 98 forks source link

Unable to download mini-seqFISH data #752

Closed MomenehForoutan closed 8 months ago

MomenehForoutan commented 1 year ago

Hi team, Just a quick note to say that when trying to pull the mini-seqFISH data through getSpatialDataset() function mentioned here, it seems that it uses a link that does not exist; so it throughs an ERROR. Currently it expects this link "https://github.com/drieslab/spatial-datasets/data/2023_spatial_genomics_mouse_kidney/Raw.zip" as per WARNING message, while it seems that the mini-seqFISH data is available under this link "https://github.com/drieslab/spatial-datasets/tree/master/data/2022_miniseqFISH".

Here is the WARNING and ERROR:

Warning: Discarded single-line footer: <<sg_mini_kidney https://github.com/drieslab/spatial-datasets/data/2023_spatial_genomics_mouse_kidney/Raw.zip    >>Selected dataset links for: mini_seqFISH
Download expression matrix:
Error in if (expr_matrix_url == "") { : argument is of length zero

I am using Giotto v.3.3.1, and here is my Session Info:

R version 4.3.1 (2023-06-16)
Platform: x86_64-redhat-linux-gnu (64-bit)
Running under: CentOS Stream 8

Matrix products: default
BLAS/LAPACK: /usr/lib64/libopenblaso-r0.3.15.so;  LAPACK version 3.9.0

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C             LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

time zone: UTC
tzcode source: system (glibc)

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

other attached packages:
 [1] GiottoData_0.2.5 lubridate_1.9.2  forcats_1.0.0    stringr_1.5.0    dplyr_1.1.2      purrr_1.0.2      readr_2.1.4     
 [8] tidyr_1.3.0      tibble_3.2.1     ggplot2_3.4.3    tidyverse_2.0.0  rmarkdown_2.24   Giotto_3.3.1    

loaded via a namespace (and not attached):
 [1] gtable_0.3.4      xfun_0.40         remotes_2.4.2.1   htmlwidgets_1.6.2 devtools_2.4.5    processx_3.8.2    lattice_0.21-8   
 [8] callr_3.7.3       tzdb_0.4.0        vctrs_0.6.3       tools_4.3.1       ps_1.7.5          generics_0.1.3    fansi_1.0.4      
[15] pkgconfig_2.0.3   Matrix_1.6-1      data.table_1.14.8 lifecycle_1.0.3   compiler_4.3.1    munsell_0.5.0     terra_1.7-39     
[22] codetools_0.2-19  httpuv_1.6.11     usethis_2.2.2     htmltools_0.5.6   yaml_2.3.7        urlchecker_1.0.1  crayon_1.5.2     
[29] pillar_1.9.0      later_1.3.1       ellipsis_0.3.2    cachem_1.0.8      sessioninfo_1.2.2 mime_0.12         tidyselect_1.2.0 
[36] digest_0.6.33     stringi_1.7.12    fastmap_1.1.1     grid_4.3.1        colorspace_2.1-0  cli_3.6.1         magrittr_2.0.3   
[43] pkgbuild_1.4.2    utf8_1.2.3        withr_2.5.0       prettyunits_1.1.1 scales_1.2.1      promises_1.2.1    rappdirs_0.3.3   
[50] timechange_0.2.0  reticulate_1.31   png_0.1-8         hms_1.1.3         memoise_2.0.1     shiny_1.7.5       evaluate_0.21    
[57] knitr_1.43        miniUI_0.1.1.1    profvis_0.3.8     rlang_1.1.1       Rcpp_1.0.11       xtable_1.8-4      glue_1.6.2       
[64] pkgload_1.3.2.1   rstudioapi_0.15.0 jsonlite_1.8.7    R6_2.5.1          fs_1.6.3         

Many thanks! Sepideh

rbutleriii commented 9 months ago

Seems to be a truncated datasets.txt file in the GiottoData package. Long term I believe they are migrating to loadGiottoMini

> seqfish_mini = loadGiottoMini("seqfish")
To be implemented

You can fix it by adding two tab to the bottom line, then adding the filepaths yourself on the next line. but it would be easier to wget it directly:

system("wget -P data https://github.com/drieslab/spatial-datasets/raw/master/data/2022_miniseqFISH/seqfish_field_expr.txt.gz")
system("wget -P data https://github.com/drieslab/spatial-datasets/raw/master/data/2022_miniseqFISH/seqfish_field_locs.txt")
# LR_data = fread(system.file("extdata", "mouse_ligand_receptors.txt", package = 'GiottoData'))
josschavezf commented 8 months ago

hi @MomenehForoutan and @rbutleriii

I just updated GiottoData to download the mini_seqFISH dataset using:

library(GiottoData) seqfish_mini = loadGiottoMini("seqfish", python_path = NULL)

@MomenehForoutan I see you're still using Giotto v3, I recommend installing the most recent version of Giotto 4.0.2 with devtools::install_github("drieslab/Giotto")

I also updated the tutorial on the website: https://drieslab.github.io/Giotto/articles/mini_seqfish.html

rbutleriii commented 8 months ago

Confirmed with all the mini datasets c("visium", "seqfish", "starmap", "vizgen", "cosmx", "spatialgenomics"). Should the GiottoData version update with this? I think has been 0.2.6.2 for a while.

josschavezf commented 8 months ago

Done, version was updated to 0.2.7.0