simplebench.utils.machine_info module🔗
Utility functions to get machine information.
- class simplebench.utils.machine_info.MachineInfo[source]🔗
Bases:
TypedDictTypedDict for machine info returned by
get_machine_info().- Variables:
processor (str) – Processor name.
machine (str) – Machine type.
python_compiler (str) – Python compiler used.
python_implementation (str) – Python implementation name.
python_implementation_version (str) – Python implementation version.
python_version (str) – Python version.
python_build (tuple[str, str]) – Python build information.
release (str) – Operating system release.
system (str) – Operating system name.
- simplebench.utils.machine_info.get_machine_info() MachineInfo[source]🔗
Return a dictionary of information about the current machine and Python version.
- simplebench.utils.machine_info.platform_architecture() str[source]🔗
Return the current architecture.
- Returns:
The architecture.
- Return type:
- simplebench.utils.machine_info.platform_id() str[source]🔗
Return a string that uniquely identifies the current machine and Python version.
The platform ID is a lowercase string that combines the operating system, Python implementation, Python version, and architecture.
- Returns:
The platform ID.
- Return type:
- simplebench.utils.machine_info.platform_implementation() str[source]🔗
Return the current Python implementation name.
See
platform.python_implementation()for details.- Returns:
The Python implementation name.
- Return type:
- simplebench.utils.machine_info.platform_machine() str[source]🔗
Return the current machine type.
- Returns:
The machine type.
- Return type:
- simplebench.utils.machine_info.platform_processor() str[source]🔗
Return the current processor name.
- Returns:
The processor name.
- Return type:
- simplebench.utils.machine_info.platform_system() str[source]🔗
Return the current operating system name.
- Returns:
The operating system name.
- Return type:
- simplebench.utils.machine_info.platform_version() str[source]🔗
Return the current Python version.
- Returns:
The Python version.
- Return type:
- simplebench.utils.machine_info.python_implementation_version() str[source]🔗
Return the Python implementation version.
For CPython, this is the same as
platform.python_version(). For PyPy, this is the PyPy version (e.g., ‘7.3.5’).- Returns:
The Python implementation version.
- Return type: