scenicplus
scenicplus copied to clipboard
export_pseudobulk error
Hi! I am using SCENIC+ and I am having an issue in the 'Generate pseudobulk ATAC-seq profiles, call peaks and generate a consensus peak set' step.
I am using the following code to create the bed and bw files:
from pycisTopic.pseudobulk_peak_calling import export_pseudobulk
bw_paths, bed_paths = export_pseudobulk(input_data = cell_data,
variable = 'cell_type', # variable by which to generate pseubulk profiles, in this case we want pseudobulks per celltype
sample_id_col = 'sample_id',
chromsizes = chromsizes,
bed_path = 'work_dir', # specify where pseudobulk_bed_files should be stored
bigwig_path = 'wor_dir',# specify where pseudobulk_bw_files should be stored
path_to_fragments = fragments_dict, # location of fragment fiels
n_cpu = 8, # specify the number of cores to use, we use ray for multi processing
normalize_bigwig = True,
remove_duplicates = True,
_temp_dir = os.path.join(tmp_dir, 'ray_spill'),
split_pattern = '-')
The outup that I am getting is the following:
INFO worker.py:1538 -- Started a local Ray instance.
(export_pseudobulk_ray pid=34990) 2023-05-01 17:15:54,946 cisTopic INFO Creating pseudobulk for Endocrine_dorsal_pancreas
(export_pseudobulk_ray pid=34989) 2023-05-01 17:15:55,249 cisTopic INFO Creating pseudobulk for anteriorpharynx
(export_pseudobulk_ray pid=34993) 2023-05-01 17:15:55,563 cisTopic INFO Creating pseudobulk for blood
(export_pseudobulk_ray pid=34992) 2023-05-01 17:15:55,941 cisTopic INFO Creating pseudobulk for epithelium_ductalcells
(export_pseudobulk_ray pid=34988) 2023-05-01 17:15:56,248 cisTopic INFO Creating pseudobulk for liver
(export_pseudobulk_ray pid=34986) 2023-05-01 17:15:56,787 cisTopic INFO Creating pseudobulk for pharyngealendoderm
(export_pseudobulk_ray pid=34987) 2023-05-01 17:15:57,284 cisTopic INFO Creating pseudobulk for vasculature
It seems to be lacking the message that it has been done and the files are not created.
Any idea why this could be happening?
Hi @mtrebelo
Does any of cell type labels contain spaces or special characters?
Also I see that bigwig_path
is set to 'wor_dir'`` instead of
'work_dir'`.
Besides these things you can try setting n_cpu
to 1, this will reveal all error messages (ray is not passing them correctly).
I hope this helps!
Best,
Seppe
Hi @SeppeDeWinter,
Thanks for your helping. I have similar issue and I can't get output files in "pseudobulk_bed_files" and "pseudobulk_bw_files" dir. Can you help me to solve this?
Best, Mahan
Hi @MohammadIzadi
Did you try running the code with single cpu core?
Best,
Seppe
I got the same error, and it said the package pyrle was missing, so after installing pyrle the output files appeared. Perhaps it is not correctly defined in the dependencies?