Skip to main content

PyArchitecture

PyArchitecture is a lightweight python module to get kernel information via OS specific CLI commands.

Python

Platform

pypi functional-tests

Pypi Pypi-format Pypi-status

Summary

PyArchitecture is designed to retrieve hard-to-find kernel information like CPU/GPU model name, physical disks, and memory profiles without using any external dependencies.

Although this project does not rely on external dependencies, it does use system tools, as outlined below.

Library / Override Linux Darwin (macOS) Windows
CPU
cpu_lib
/proc/cpuinfo /usr/sbin/sysctl C:\Windows\System32\wbem\wmic.exe
PCI
gpu_lib
/usr/bin/lspci /usr/sbin/system_profiler C:\Windows\System32\wbem\wmic.exe
Memory
mem_lib
/proc/meminfo /usr/sbin/sysctl N/A
Disk
disk_lib
/usr/bin/lsblk /usr/sbin/diskutil C:\Program Files\PowerShell\7\pwsh.exe

Installation

pip install PyArchitecture

Usage

Initiate - IDE

import pyarchitecture

if __name__ == '__main__':
    all_disks = pyarchitecture.disks.get_all_disks()
    print(all_disks)
    cpu_info = pyarchitecture.cpu.get_cpu_info()
    print(cpu_info)
    gpu_info = pyarchitecture.gpu.get_gpu_info()
    print(gpu_info)
    mem_info = pyarchitecture.memory.get_memory_info()
    print(mem_info)

Initiate - CLI

pyarchitecture all

Use pyarchitecture --help for usage instructions.

Release Notes

Requirement

python -m pip install gitverse

Usage

gitverse-release reverse -f release_notes.rst -t 'Release Notes'

Linting

pre-commit will ensure linting

Requirement

python -m pip install pre-commit

Usage

pre-commit run --all-files

Pypi Package

pypi-module

https://pypi.org/project/PyArchitecture/

© Vignesh Rao

Licensed under the MIT License

Metadata

Release files for PyArchitecture 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for PyArchitecture 0.3.1
File Interpreter ABI Platform Actions
PyArchitecture-0.3.1-py3-none-any.whl Python 3 none any Details for PyArchitecture-0.3.1-py3-none-any.whl

Release files / PyArchitecture-0.3.1-py3-none-any.whl

Download URL PyArchitecture-0.3.1-py3-none-any.whl
Size 19.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
dec56923836b7f19a07d0f92b41db52ba6073f374d841b82bf33749f6d024a85
BLAKE2b-256 checksum
How to use checksums
0afd65498e1dba7dbd0b01825e61db230c1e9aaa0277601f5f9d487072837637
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.10.14

Security for PyArchitecture 0.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page