zhengxwen / SNPRelate

R package: parallel computing toolset for relatedness and principal component analysis of SNP data (Development version only)
http://www.bioconductor.org/packages/SNPRelate
98 stars 25 forks source link

LDpruning really using num.threads? #59

Open rafalcode opened 5 years ago

rafalcode commented 5 years ago

I've set this parameter on the snpgdsLDpruning() function and I even get back Working space: 316 samples, 795,668 SNPs using 24 (CPU) cores however every time I look at cpu usage (say, using htop) only one processor is being used. Moreover there is very little difference in time taken when num.thread=1 and 24. So I feel something is up.

zhengxwen commented 5 years ago

No multithreaded support.

rafalcode commented 5 years ago

OK, thanks, it's in the console output ... my eyes missed it :-( But it came at the end, after the "using 24" came up ... As I quick fix, to avoid confusion/ disappointment, may I suggest the following? In LD.R, @ .InitFIle2() call cmd=paste(ifelse(inherits(gdsobj, "SeqVarGDSClass"), "SNV", "SNP"), "pruning based on LD (single core only, disregard using CPU comment below):"), gdsobj = etc.)