# Performance Lens 1.0.2

A live CPU, GPU, RAM and VRAM dashboard for Linux by Dustin Pressley / Pressley
Services. Native Python / GTK 4 / libadwaita, MIT license.

## Install

    sh performance-lens-1.0.2-fedora.run

Run as your normal desktop user. The single file embeds the complete app, icon
and GNOME extension. Missing native libraries come from your distribution's repositories
using sudo. Requires Python 3.10+, PyGObject/Cairo, GTK 4.10+, libadwaita 1.5+ and
Linux procfs/sysfs. pciutils provides readable GPU names. No Python packages,
containers or language package manager are needed. Once OS libraries exist,
installation and operation work offline.

    sh performance-lens-1.0.2-fedora.run --check
    sh performance-lens-1.0.2-fedora.run --no-deps
    sh performance-lens-1.0.2-fedora.run --extract=./extracted
    ~/.local/bin/performance-lens --uninstall

Installs under ~/.local/share and ~/.local/bin for your account. Open from
Applications or the Performance button in GNOME Quick Settings. New extensions
may need one sign-out/sign-in. GNOME 45–51 is targeted; Fedora 44 / GNOME 50 and Fedora 45 / GNOME 51 are tested separately. Other desktop environments use the Applications launcher. This release
has dedicated x86-64 installers for the seven distributions listed below.

## Readings

Samples refresh approximately once per second in a background worker. Four live
charts retain the last 60 seconds: CPU busy time, selected GPU load, RAM in use,
and selected GPU memory capacity used. Fixed 0–100% axes and gaps for unavailable
samples. Select each GPU separately; memory pools are never added across GPUs.

CPU: aggregate and per-logical-thread deltas from /proc/stat. Idle and I/O wait
are excluded from busy time, and guest counters are not added twice. The first
sample warms up the counters. Reported clock averages the driver's exported
frequencies; it is not a benchmark or an effective-clock measurement. Temperature
is the highest exported compatible CPU sensor; missing sensors stay unknown.
Load averages are task counts, not percentages.

RAM in use = MemTotal − MemAvailable. Available includes reclaimable memory;
cache is not extra RAM and overlaps these totals. Swap includes compressed-RAM
and disk swap as configured by the OS. No inaccurate MemFree-only fallback.

NVIDIA: existing nvidia-smi driver tool, CSV queries with a two-second timeout.
GPU busy %, VRAM capacity/use, temperature, GPU power and graphics/memory clocks
where supported. The installer does not install or replace GPU drivers. NVIDIA
monitoring can keep a laptop's discrete GPU awake; disable Monitor NVIDIA to
stop its queries while keeping CPU/RAM/other GPU readings live.

AMD: amdgpu sysfs GPU busy, driver VRAM and system-backed GTT allocation counters,
plus hwmon temperature/power/clocks where exported. On integrated graphics,
driver-reported VRAM may be reserved system RAM, not separate physical VRAM.
GTT is system-backed GPU memory and is not added to RAM totals or dedicated VRAM.
Intel/other drivers are detected, with partial sensor data where available;
global load/VRAM counters are unavailable if the driver exposes no supported API.
No privileged performance-counter helper is installed and no access groups change.

Pause stops new collections and freezes the view. Resume resets CPU deltas and
leaves a graph gap. Slow or failing queries show their state instead of invented
zeroes. Hardware counters and drivers determine what can be measured.

## Privacy and controls

No networking, telemetry, automatic logging, background daemon, clock/fan/power
changes, overclocking, process control or driver installation. Polling happens
only while the window is open and unpaused. Closing it stops collection and any
owned query process. Export is an explicit local JSON snapshot, including GPU
names/PCI locations and current readings. Review exports before sharing.

Ctrl+P pause; Ctrl+R sample now; Ctrl+E export; Ctrl+Q quit.

    ~/.local/bin/performance-lens --json
    ~/.local/bin/performance-lens --demo

The JSON command takes a real CPU interval. Demo opens a separately identified,
clearly labeled illustrative preview without querying hardware.

## Build

    /usr/bin/python3 build.py
    /usr/bin/python3 -m pytest tests/test_backend.py tests/test_distributables.py
    /usr/bin/python3 tests/check-fedora.py
    /usr/bin/python3 packaging/release.py

The app zipapp uses deterministic entry metadata. Each distribution installer
embeds and verifies that payload. Release packaging checks exact installer and
app hashes against retained Fedora test evidence, including real CPU/memory,
both physical GPUs on this host, GTK behavior, GNOME shortcut launch, reinstall
and uninstall. GPU families without physical test hardware are not claimed as
verified. The current release also runs through the shared, serial per-distribution VM validation suite.

Telemetry references: [Linux procfs](https://docs.kernel.org/filesystems/proc.html),
[AMDGPU memory accounting](https://docs.kernel.org/gpu/amdgpu/driver-misc.html),
[NVIDIA System Management Interface](https://docs.nvidia.com/deploy/nvidia-smi/index.html).

## Window-layout update 1.0.2

Adaptive charts, stacked detail panels and a narrower CPU grid support GNOME
left/right tiling and scaled displays. Validated at 480, 640, 768, 960 and 1180
pixels wide, including short windows and actual GNOME left/right tiling.


## Distribution-wide update

The current release targets Fedora, Ubuntu, Debian, Kali Linux, Linux Mint, Arch Linux and openSUSE Leap. Every distro has its own installer with native package dependencies. Responsive layouts and GNOME menu integration are shared across the builds. GNOME provides the Quick Settings buttons; other desktops receive their standard Applications-menu launcher.

The cross-distribution release suite installs, runs, exercises live data and responsive layouts, verifies the desktop launcher, and uninstalls all four dashboards on each VM before deleting that VM and moving to the next distribution. See the release validation report for tested versions and hardware limits. Virtual GPUs may expose no GPU/VRAM usage counters; those values stay unavailable rather than being fabricated. Website updates and publishing are a later stage.


### Current target baselines

The distribution-wide release uses separate x86-64 installers for Fedora, Ubuntu, Debian, Kali, Linux Mint, Arch and openSUSE Leap. Validation targets Fedora **44 and 45 separately**, Ubuntu 24.04 LTS, Debian 13, Kali 2026.3, Linux Mint 22.3 Cinnamon, Arch rolling and openSUSE Leap 16.0. Other releases are not automatically claimed tested. The same Fedora installer is exercised on both Fedora versions.

Use the installer whose suffix matches your distribution, for example `-fedora.run`, `-ubuntu.run` or `-linuxmint.run`. GNOME supplies the Quick Settings button (or Network Lens’s existing Wi-Fi submenu action); other desktops receive native Applications-menu launchers. A new GNOME extension may require one sign-out/sign-in. The per-app all-distro bundle includes the current test report and exact installer checksums. The full release matrix covers 28 unique files / 32 installer-VM combinations.
