code: def _num_cpus_darwin():
      """Return the number of active CPUs on a Darwin system."""
      p = subprocess.Popen(
          ["sysctl", "-n", "hw.ncpu"], stdout=subprocess.PIPE
      )
      return p.stdout.read()
  
file_path: catboost/contrib/python/ipython/py2/IPython/utils/sysinfo.py
imports: import os
  import platform
  import pprint
  import sys
  import subprocess
  from IPython.core import release
  from IPython.utils import py3compat, _sysinfo, encoding
label_desc: Use image node_id 6 for calling a global function with example usage: _num_cpus_darwin() and returns: p