A single-file, dependency-light Windows monitoring tool (Python) focused on real-time CPU + memory + kernel + paging visibility, with an optional GPU block (via Windows Performance Counters).
This is designed to be run in a terminal and refreshed continuously (like a lightweight top for Windows, but with paging + kernel memory focus).
- Overall CPU utilization (rolling)
- Per-core utilization
- Per-core effective clock (GHz) and normalized speed (% of max observed)
- Detects and displays core counts and hybrid/core labeling when available
- Physical Total / Available
- Commit Total / Commit Limit
- Kernel Paged and Non-Paged pool
- Swap/Pagefile total/used/free (via
psutil)
- Page Faults/sec (PF/s) + EMA smoothing
- Pages/sec + EMA smoothing
- Page Reads/sec + EMA smoothing
- PagingFile(*) % Usage
- Memory\Available Bytes
- Derived HardFaultPressure index (0–100) and qualitative label (OK/WARN/HOT)
- “Compressed” memory estimate using the MemCompression process RSS (working set)
- Top processes by CPU%
- Top processes by RSS (working set)
- Handles / processes / threads totals
- Overall GPU utilization (aggregated from GPU engine counters)
- Per-engine breakdown (top engine categories), typically:
3D,Copy,Compute,VideoDecode,VideoEncode(others may appear depending on driver)
- GPU adapter memory usage:
- Dedicated usage
- Shared usage
Example GPU line:
GPU: Util: 2.6% | Engines: 3D:2.6% | Copy:0.2% | ... | Mem: Dedicated 853.36 MB | Shared 661.43 MB
- Windows 10/11
- Python 3.9+ recommended (3.8+ typically OK)
- No Visual Studio / compilation required
Install:
python -m pip install --upgrade pip
python -m pip install psutil(Everything else is standard library: ctypes, time, datetime, etc.)
python .\native_win_monitor_v29.pySome counters or process visibility can be restricted on certain systems. If you see Access is denied or missing counters, run PowerShell or Windows Terminal as Administrator:
python .\native_win_monitor_v29.pyStop anytime with Ctrl+C.
- Page Faults/sec includes soft faults and hard faults (not all are disk I/O).
- Pages/sec is a stronger indicator of paging activity (potentially hard faults).
- Page Reads/sec indicates paging reads from disk and is often the most “painful” when elevated.
A simple heuristic derived from Page Reads/sec and Pages/sec:
- OK: low paging pressure
- WARN: noticeable paging activity
- HOT: sustained hard faults / disk reads likely impacting responsiveness
Windows memory compression isn’t always exposed as a clean global counter. This tool estimates it using the MemCompression process working set.
GPU values come from Windows Performance Counters:
\GPU Engine(*)\Utilization Percentage\GPU Adapter Memory(*)\Dedicated Usage\GPU Adapter Memory(*)\Shared Usage
Some drivers expose extra engine categories (e.g., Security, High). That’s normal.
Some counters may be missing or named differently on certain Windows builds/locales. The tool already tries multiple counter path variants.
Examples:
typeperf "\Memory\Page Faults/sec" -sc 3
typeperf "\Memory\Pages/sec" -sc 3
typeperf "\Memory\Page Reads/sec" -sc 3
typeperf "\Paging File(*)\% Usage" -sc 3
typeperf "\Memory\Available Bytes" -sc 3
typeperf "\GPU Engine(*)\Utilization Percentage" -sc 3
typeperf "\GPU Adapter Memory(*)\Shared Usage" -sc 3Some systems (or drivers) may not expose GPU Engine counters. Task Manager may still show GPU usage even if counters are missing.
Run PowerShell/Terminal as Administrator (recommended / some environments).
windows-kernel-monitor/
native_win_monitor_v29.py
README.md
LICENSE
If you prefer the canonical filename to stay native_win_monitor.py, rename:
Rename-Item .\native_win_monitor_v29.py native_win_monitor.pyMIT License. See LICENSE.
PRs welcome. If you’re adding new counters:
- Prefer PDH counters when available (portable and scriptable)
- Keep the terminal output stable and readable (avoid overly wide lines)
- Add a
typeperfverification line to this README when introducing new counters