()
| 104 | |
| 105 | |
| 106 | def get_system_info() -> Dict[str, str]: |
| 107 | info = { |
| 108 | "OS": f"{platform.system()} {platform.release()}", |
| 109 | "Machine": platform.machine(), |
| 110 | "Processor": platform.processor() or "Unknown", |
| 111 | "Python": platform.python_version(), |
| 112 | } |
| 113 | if HAS_PSUTIL: |
| 114 | info["CPU Cores (Physical)"] = str(psutil.cpu_count(logical=False)) |
| 115 | info["CPU Cores (Logical)"] = str(psutil.cpu_count(logical=True)) |
| 116 | info["Total RAM (GB)"] = str( |
| 117 | round(psutil.virtual_memory().total / (1024**3), 2) |
| 118 | ) |
| 119 | return info |
| 120 | |
| 121 | |
| 122 | def format_datatype_label(datatype: str) -> str: |
no test coverage detected