Skip to main content

cpu_cores-py is a small python library to get the number of'real physical' cpu cores of a linux/osx box

Project description

What is it ?

cpu_cores is small python library and utility to get the number of “physical” cpu cores (without hyperthreading logical cores) of a linux/osx box.

On Linux, this is not an easy task because of hyperthreaded logical cores included in /proc/cpuinfo. Please, read carefully this excellent post to understand why.

Special features

  • support Linux (well tested) and OSX (needs some extra tests files), easy to extend to support other OS
  • unit tests (> 90% coverage)
  • python2 and python3 support
  • no dependencies


See the README for more details.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for cpu_cores, version 0.1.3
Filename, size & hash File type Python version Upload date
cpu_cores-0.1.3.tar.gz (8.6 kB) View hashes Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page