Name | envdetect JSON |
Version |
0.1.0
JSON |
| download |
home_page | None |
Summary | A lightweight Python package to detect environment details like OS, CPU, memory, GPU, and Python runtime. |
upload_time | 2025-08-17 10:39:33 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.7 |
license | None |
keywords |
environment
system
os
cpu
memory
gpu
python
detection
|
VCS |
 |
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# EnvDetect
EnvDetect is a lightweight Python library for detecting detailed system environment information, including OS, CPU, memory, GPU, Python runtime, and installed packages.
It can be used for debugging, reproducibility, environment validation, or as part of ML/AI pipelines where knowing the exact system setup is crucial.
---
## Features
- **OS Information**: Name, version, release, architecture, and more.
- **CPU Information**: Count, frequency, brand, cores, cache sizes, etc.
- **Memory Information**: Total, available, used, swap, and percentages.
- **GPU Information**: Vendor, name, driver version, VRAM, and more (if available).
- **Python Runtime**: Version, implementation, executable path, installed packages.
- **Environment Summary**: Aggregates all details into one dictionary for easy export/logging.
---
## Installation
```bash
pip install envdetect
```
## Usage
```python
from envdetect import os_info, cpu_info, memory_info, gpu_info, python_info, environment_summary
print("=== OS Info ===")
print(os_info())
print("=== CPU Info ===")
print(cpu_info())
print("=== Memory Info ===")
print(memory_info())
print("=== GPU Info ===")
print(gpu_info())
print("=== Python Info ===")
print(python_info())
print("=== Full Environment Summary ===")
print(environment_summary())
```
## CLI
```bash
python -m envdetect
```
This will print a full environment summary in JSON format.
### Example Output
```json
{
"os": {
"system": "Linux",
"release": "5.15.0-78-generic",
"version": "#85-Ubuntu SMP Tue Jun 6 23:34:54 UTC 2023",
"architecture": ["64bit", "ELF"],
"machine": "x86_64",
"processor": "Intel(R) Xeon(R) CPU"
},
"cpu": {
"physical_cores": 4,
"total_cores": 8,
"cpu_freq_mhz_max": 4200.0,
"cpu_freq_mhz_min": 800.0,
"cpu_freq_mhz_current": 2300.0,
"l1_cache_kb": 256,
"l2_cache_kb": 1024,
"l3_cache_kb": 8192,
"brand": "Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz"
},
"memory": {
"total": 16,
"available": 10.5,
"used": 5.3,
"percent": 34.5,
"swap_total": 2,
"swap_used": 0.1,
"swap_free": 1.9
},
"gpu": [
{
"id": "GPU-0",
"name": "NVIDIA GeForce RTX 3070",
"driver_version": "535.54",
"memory_total_MB": 8000,
"memory_free_MB": 6500,
"memory_used_MB": 1500
}
],
"python": {
"version": "3.10.12",
"implementation": "CPython",
"executable": "/usr/bin/python3",
"packages_count": 240
}
}
```
## Running Tests
```bash
python -m unittest discover -s tests
```
Raw data
{
"_id": null,
"home_page": null,
"name": "envdetect",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": null,
"keywords": "environment, system, os, cpu, memory, gpu, python, detection",
"author": null,
"author_email": "SoftwareApkDev <softwareapkdev2022@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/9d/f0/867ce3c44ac764659c68bb35c63d7ac30aaa18839cfe8560febbb4670a21/envdetect-0.1.0.tar.gz",
"platform": null,
"description": "# EnvDetect\n\nEnvDetect is a lightweight Python library for detecting detailed system environment information, including OS, CPU, memory, GPU, Python runtime, and installed packages. \n\nIt can be used for debugging, reproducibility, environment validation, or as part of ML/AI pipelines where knowing the exact system setup is crucial.\n\n---\n\n## Features\n\n- **OS Information**: Name, version, release, architecture, and more. \n- **CPU Information**: Count, frequency, brand, cores, cache sizes, etc. \n- **Memory Information**: Total, available, used, swap, and percentages. \n- **GPU Information**: Vendor, name, driver version, VRAM, and more (if available). \n- **Python Runtime**: Version, implementation, executable path, installed packages. \n- **Environment Summary**: Aggregates all details into one dictionary for easy export/logging.\n\n---\n\n## Installation\n\n```bash\npip install envdetect\n```\n\n## Usage\n\n```python\nfrom envdetect import os_info, cpu_info, memory_info, gpu_info, python_info, environment_summary\n\nprint(\"=== OS Info ===\")\nprint(os_info())\n\nprint(\"=== CPU Info ===\")\nprint(cpu_info())\n\nprint(\"=== Memory Info ===\")\nprint(memory_info())\n\nprint(\"=== GPU Info ===\")\nprint(gpu_info())\n\nprint(\"=== Python Info ===\")\nprint(python_info())\n\nprint(\"=== Full Environment Summary ===\")\nprint(environment_summary())\n```\n\n## CLI\n\n```bash\npython -m envdetect\n```\n\nThis will print a full environment summary in JSON format.\n\n### Example Output\n\n```json\n{\n \"os\": {\n \"system\": \"Linux\",\n \"release\": \"5.15.0-78-generic\",\n \"version\": \"#85-Ubuntu SMP Tue Jun 6 23:34:54 UTC 2023\",\n \"architecture\": [\"64bit\", \"ELF\"],\n \"machine\": \"x86_64\",\n \"processor\": \"Intel(R) Xeon(R) CPU\"\n },\n \"cpu\": {\n \"physical_cores\": 4,\n \"total_cores\": 8,\n \"cpu_freq_mhz_max\": 4200.0,\n \"cpu_freq_mhz_min\": 800.0,\n \"cpu_freq_mhz_current\": 2300.0,\n \"l1_cache_kb\": 256,\n \"l2_cache_kb\": 1024,\n \"l3_cache_kb\": 8192,\n \"brand\": \"Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz\"\n },\n \"memory\": {\n \"total\": 16,\n \"available\": 10.5,\n \"used\": 5.3,\n \"percent\": 34.5,\n \"swap_total\": 2,\n \"swap_used\": 0.1,\n \"swap_free\": 1.9\n },\n \"gpu\": [\n {\n \"id\": \"GPU-0\",\n \"name\": \"NVIDIA GeForce RTX 3070\",\n \"driver_version\": \"535.54\",\n \"memory_total_MB\": 8000,\n \"memory_free_MB\": 6500,\n \"memory_used_MB\": 1500\n }\n ],\n \"python\": {\n \"version\": \"3.10.12\",\n \"implementation\": \"CPython\",\n \"executable\": \"/usr/bin/python3\",\n \"packages_count\": 240\n }\n}\n```\n\n## Running Tests\n\n```bash\npython -m unittest discover -s tests\n```\n",
"bugtrack_url": null,
"license": null,
"summary": "A lightweight Python package to detect environment details like OS, CPU, memory, GPU, and Python runtime.",
"version": "0.1.0",
"project_urls": {
"Homepage": "https://github.com/SoftwareApkDev/envdetect",
"Issues": "https://github.com/SoftwareApkDev/envdetect/issues",
"Repository": "https://github.com/SoftwareApkDev/envdetect"
},
"split_keywords": [
"environment",
" system",
" os",
" cpu",
" memory",
" gpu",
" python",
" detection"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "14a417ea36c8f287f4789151cc8eedb912d262eb94f5592f947a34a2c4344419",
"md5": "e7d9890a1e4b6c44a5fb062a6cfd1a55",
"sha256": "160658c58b9cf6c678b857862262cb893a2bf3b19869c614d0fbf787c470b960"
},
"downloads": -1,
"filename": "envdetect-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "e7d9890a1e4b6c44a5fb062a6cfd1a55",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 2427,
"upload_time": "2025-08-17T10:39:31",
"upload_time_iso_8601": "2025-08-17T10:39:31.733462Z",
"url": "https://files.pythonhosted.org/packages/14/a4/17ea36c8f287f4789151cc8eedb912d262eb94f5592f947a34a2c4344419/envdetect-0.1.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "9df0867ce3c44ac764659c68bb35c63d7ac30aaa18839cfe8560febbb4670a21",
"md5": "8bff24272baa70b5e4ece3108a498cc7",
"sha256": "1615893045b3102f9a801bcd47967ead2a336a85c5db13e8795c57135d915e3f"
},
"downloads": -1,
"filename": "envdetect-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "8bff24272baa70b5e4ece3108a498cc7",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 3335,
"upload_time": "2025-08-17T10:39:33",
"upload_time_iso_8601": "2025-08-17T10:39:33.199794Z",
"url": "https://files.pythonhosted.org/packages/9d/f0/867ce3c44ac764659c68bb35c63d7ac30aaa18839cfe8560febbb4670a21/envdetect-0.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-17 10:39:33",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "SoftwareApkDev",
"github_project": "envdetect",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "envdetect"
}