Skip to content

install-python-src

Automatically generated README for this automation recipe: install-python-src

Category: Python automation

License: Apache 2.0

  • CM meta description for this script: _cm.json
  • Output cached? True

Reuse this script in your project

Install MLCommons CM automation meta-framework

Pull CM repository with this automation recipe (CM script)

cm pull repo mlcommons@cm4mlops

cmr "install src python python3 src-python3 src-python" --help

Run this script

Run this script via CLI
cm run script --tags=install,src,python,python3,src-python3,src-python[,variations] 
Run this script via CLI (alternative)
cmr "install src python python3 src-python3 src-python [variations]" 
Run this script from Python
import cmind

r = cmind.access({'action':'run'
              'automation':'script',
              'tags':'install,src,python,python3,src-python3,src-python'
              'out':'con',
              ...
              (other input keys for this script)
              ...
             })

if r['return']>0:
    print (r['error'])
Run this script via Docker (beta)
cm docker script "install src python python3 src-python3 src-python[variations]" 

Variations

  • No group (any combination of variations can be selected)

    Click here to expand this section.

    • _lto
      • ENV variables:
        • CM_PYTHON_LTO_FLAG: --lto
        • CM_PYTHON_INSTALL_CACHE_TAGS: with-lto
    • _optimized
      • ENV variables:
        • CM_PYTHON_OPTIMIZATION_FLAG: --enable-optimizations
        • CM_PYTHON_INSTALL_CACHE_TAGS: optimized
    • _shared
      • ENV variables:
        • CM_PYTHON_INSTALL_CACHE_TAGS: shared
        • CM_SHARED_BUILD: yes
    • _with-custom-ssl
      • ENV variables:
        • CM_CUSTOM_SSL: yes
        • CM_PYTHON_INSTALL_CACHE_TAGS: with-custom-ssl
  • Group "ssl"

    Click here to expand this section.

    • _with-ssl
      • ENV variables:
        • CM_ENABLE_SSL: yes
        • CM_PYTHON_INSTALL_CACHE_TAGS: with-ssl

Default environment

These keys can be updated via --env.KEY=VALUE or env dictionary in @input.json or using script flags.

  • CM_ENABLE_SSL: no
  • CM_CUSTOM_SSL: no
  • CM_SHARED_BUILD: no
  • CM_PYTHON_OPTIMIZATION_FLAG: ``
  • CM_PYTHON_LTO_FLAG: ``
  • CM_WGET_URL: https://www.python.org/ftp/python/[PYTHON_VERSION]/Python-[PYTHON_VERSION].tgz

Versions

Default version: 3.10.13

Native script being run

No run file exists for Windows


Script output

cmr "install src python python3 src-python3 src-python [variations]"  -j