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

Number of threads #57

Open
readmanchiu opened this issue Nov 25, 2024 · 4 comments
Open

Number of threads #57

readmanchiu opened this issue Nov 25, 2024 · 4 comments

Comments

@readmanchiu
Copy link

Hi,

I am running v1.2.2. I wonder why Savana would spawn out more threads than I specified with --threads?
I am trying to reduce the memory footprint at the expense of running time by using fewer number of threads, but I noticed Savana at some stage when it is running always spawned out more threads/processes than I specified.
Also, my run using 4 threads used more memory (262GB) than using 8 threads (256GB). So it seems like my assumption that Savana would use less memory if I reduce the amount of multi-processing does not hold.
Can you suggest on how I can reduce memory usage (if there is any way) then?

Thanks

@helrick
Copy link
Member

helrick commented Nov 26, 2024

Hi there! Are you running copy number analysis with SAVANA as well? If so, the higher number of threads might be at the copy number stage. If so, are you able to supply SAVANA with both the cna_threads and threads arguments? I would recommend a higher number of threads for CNA calling and a lower number for SV calling. That memory usage does indeed seem high though - may I ask what the coverage of your data is?

@readmanchiu
Copy link
Author

No I am not running cna, just sv. And the coverage is only 35-40x.
This is how I ran:

singularity exec savana_1.2.2--pyhdfd78af_0.sif savana --tumour tumor.bam --normal normal.bam --ref hg38_no_alt.fa --outdir savana_outdir  --sample sample --threads 4 --custom_model ont-somatic.pkl --length 50 --min_support 3

@helrick
Copy link
Member

helrick commented Nov 27, 2024

Are you able to supply the contigs of interest via the --contigs flag to see if that helps? There's an example file with the canonical chromosomes here

@readmanchiu
Copy link
Author

using --contigs does reduce the memory usage (98GB using 8 threads instead of 256GB). Why does using --contigs make such a big difference?
I still found more than 8 threads were spawned out, I'm not sure if it's just 9 (adding the main process) or there were more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants