fgvieira / ngsLD

Calculation of pairwise Linkage Disequilibrium (LD) under a probabilistic framework
GNU General Public License v2.0
43 stars 7 forks source link

how to increase the threads used in prune_graph.pl #22

Closed xilingsabatelli closed 3 years ago

xilingsabatelli commented 3 years ago

Hello!

I am running prune_graph.pl for my data (contains around 3 million SNPs), it takes endless time (already 19 days). I allocate 64 threads for the program by adding --n_threads, but I think this option doesn't applicable for prune_graph.pl. And I checked, the program is actually using only one thread.

So is it possible to increase the threads for prune_graph.pl to somehow make it runs faster?

Many thanks, Xiling

fgvieira commented 3 years ago

Hi Xiling,

the prune_graph.pl is not threaded, so it can be very slow.

The reason is that, it was initially made as a proof-of concept rather then for production. That is why it was made in perl and not a lot of attention was paid to optimization and such. One thing you can do, is to split the ngsLD output by contig/scaffold/chr and run the script on each one of them separately.