ksamuk / pixy

Software for painlessly estimating average nucleotide diversity within and between populations
https://pixy.readthedocs.io/
MIT License
115 stars 14 forks source link

pixy (apparently) not using all requested cores #84

Closed rafmarcondes closed 1 year ago

rafmarcondes commented 1 year ago

Hi,

I'm using pixy 1.2.7.beta1 with Python 3.8 in Mac OS Ventura. I'm asking pixy to use 8 of my 10 cores:

pixy --stats fst \
--vcf /Volumes/LaCie/ALL-SITES-FILTERED.vcf.gz \
--populations /Users/rs155/Dropbox/thamno_dna/pops_file_for_martin \
--window_size 1 \
#--bypass_invariant_check yes \
--n_cores 8 \
--output_prefix pixy_rez_fst_genome-wide_not_imputed_aspVdin.txt

But apparently it's using only 1, and is correspondingly slow:

(py38) rs155@JLWTLX9FWP july_2023 % bash pixy_run_10jul2023.sh
[pixy] pixy 1.2.7.beta1
[pixy] See documentation at https://pixy.readthedocs.io/en/latest/

[pixy] Validating VCF and input parameters...
[pixy] Checking write access...OK
[pixy] Checking CPU configuration...OK
[pixy] Checking for invariant sites...OK
[pixy] Checking chromosome data...OK
[pixy] Checking intervals/sites...OK
[pixy] Checking sample data...OK
[pixy] All initial checks past!

[pixy] Preparing for calculation of summary statistics: fst
[pixy] Using Weir and Cockerham (1984)'s estimator of FST.
[pixy] Data set contains 2 population(s), 35 chromosome(s), and 25 sample(s)
[pixy] Window size: 1 bp

[pixy] Started calculations at 12:00:27 on 2023-07-12
[pixy] Using 1 out of 10 available CPU cores

[pixy] Processing chromosome/contig chr1_cl...
[pixy] Calculating statistics for region chr1_cl:1-145745323...
Screenshot 2023-07-12 at 3 03 54 PM

What might be going on?