aertslab / scenicplus

SCENIC+ is a python package to build gene regulatory networks (GRNs) using combined or separate single-cell gene expression (scRNA-seq) and single-cell chromatin accessibility (scATAC-seq) data.
Other
165 stars 27 forks source link

Few results for menr.pkl in the 10x multiome pbmc Tutorial #232

Open bitcometz opened 9 months ago

bitcometz commented 9 months ago

Hello, thanks for this great tool !!! I try to redo the 10x multiome pbmc Tutorial

After I run the previous steps and I download the file and run:

#!wget -c https://resources.aertslab.org/cistarget/databases/homo_sapiens/hg38/screen/mc_v10_clust/region_based/hg38_screen_v10_clust.regions_vs_motifs.rankings.feather
#!wget -c https://resources.aertslab.org/cistarget/databases/homo_sapiens/hg38/screen/mc_v10_clust/region_based/hg38_screen_v10_clust.regions_vs_motifs.scores.feather
#!wget -c https://resources.aertslab.org/cistarget/motif2tf/motifs-v10nr_clust-nr.hgnc-m0.001-o0.0.tbl

rankings_db        = "/content/drive/MyDrive/02.scenicplus/hg38_screen_v10_clust.regions_vs_motifs.rankings.feather"
scores_db           =  "/content/drive/MyDrive/02.scenicplus/hg38_screen_v10_clust.regions_vs_motifs.scores.feather"
motif_annotation = "/content/drive/MyDrive/02.scenicplus/motifs-v10nr_clust-nr.hgnc-m0.001-o0.0.tbl"

tmp_dir = '/scratch/leuven/330/vsc33053/'

## run for more than three hours !!!
from scenicplus.wrappers.run_pycistarget import run_pycistarget
run_pycistarget(
    region_sets                        = region_sets,
    species                                = 'homo_sapiens',
    save_path                            = os.path.join(work_dir, 'motifs'),
    ctx_db_path                        = rankings_db,
    dem_db_path                      = scores_db,
    path_to_motif_annotations = motif_annotation,
    run_without_promoters      = True,
    n_cpu                                 = 1,
    temp_dir = os.path.join(tmp_dir, 'ray_spill'),
    annotation_version = 'v10nr_clust',
    )

import dill
menr = dill.load(open(os.path.join(work_dir, 'motifs/menr.pkl'), 'rb'))

menr['DEM_topics_otsu_All'].DEM_results('Topic8')

I got only one result, which is quite diffrent from the toturial: My results: image

the results shown in the notebook: image

Could you please help with this problem ?

Thanks !!!

SeppeDeWinter commented 9 months ago

Hi @bitcometz

Thanks for the kind words.

Could you show the regions you have for this topic?

Best,

Seppe

bitcometz commented 9 months ago

hi, @SeppeDeWinter , thanks for your help. I am new to this great tool: I hope that I haven't misunderstood your intention:

image

SeppeDeWinter commented 9 months ago

Hi @bitcometz

You also re-ran topic modeling for this analysis? Because if you did your topic 8 and my topic 8 will not correspond to each other. You have to visualise your topics on a UMAP/tSNE/heatmap to get the topic specific to B-cels.

Best,

Seppe

bitcometz commented 9 months ago

Thanks for your quick reply !!! @SeppeDeWinter Yes, I run all the steps. And I download the files with this URL:

#!wget -c https://resources.aertslab.org/cistarget/databases/homo_sapiens/hg38/screen/mc_v10_clust/region_based/hg38_screen_v10_clust.regions_vs_motifs.rankings.feather
#!wget -c https://resources.aertslab.org/cistarget/databases/homo_sapiens/hg38/screen/mc_v10_clust/region_based/hg38_screen_v10_clust.regions_vs_motifs.scores.feather
#!wget -c https://resources.aertslab.org/cistarget/motif2tf/motifs-v10nr_clust-nr.hgnc-m0.001-o0.0.tbl

rankings_db        = "/content/drive/MyDrive/02.scenicplus/hg38_screen_v10_clust.regions_vs_motifs.rankings.feather"
scores_db           =  "/content/drive/MyDrive/02.scenicplus/hg38_screen_v10_clust.regions_vs_motifs.scores.feather"
motif_annotation = "/content/drive/MyDrive/02.scenicplus/motifs-v10nr_clust-nr.hgnc-m0.001-o0.0.tbl"

Yes, I think you are right. I will visualise topics on a UMAP/tSNE/heatmap to get the topic specific to B-cels.

Thanks for your help !!