Repository navigation
New Learning Path: Measure llama.cpp energy per token on a Raspberry Pi 5 with the PMIC ADC - #3908
Merged
jasonrandrews merged 3 commits intoOct 27, 2026
Conversation
…Pi 5 with the PMIC ADC Reads the Raspberry Pi 5 PMIC with vcgencmd pmic_read_adc, logs rail power with time stamps, aligns the samples with llama-bench token generation only, and compares joules per token across clock caps and thread counts. Includes the sampler overhead measurement. Adds PMIC, pmic and vcgencmd to .wordlist.txt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Resolve .wordlist.txt as a union of both sides' additions. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Signed-off-by: manunicholasjacob <manunicholasjacob@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New Learning Path: Measure llama.cpp energy per token on a Raspberry Pi 5 with the PMIC ADC (
content/learning-paths/embedded-and-microcontrollers/rpi5-energy-per-token/).The Raspberry Pi 5 has no
hwmonpower or current sensors, so the existing performance-per-watt path cannot be followed on it. This path reads the Pi 5 PMIC withvcgencmd pmic_read_adc, logs rail power with a time stamp on every sample, lines the samples up with llama-bench token generation only (model load and warmup excluded, using the--progresslines andsamples_ns), and reports joules per token with and without the idle power. It then compares clock caps and thread counts and measures how much the sampler itself slows llama.cpp down.What is in the PR
_index.md,_next-steps.mdand 4 pages: read the PMIC, log power, measure joules per token, compare clock caps and threads.embedded-and-microcontrollers, subject Performance and Architecture, Advanced, 60 minutes..wordlist.txt(PMIC, pmic, vcgencmd). The contributors.csv row already exists.How it was tested
836d571, official Qwen2.5 0.5B Instruct Q4_0 GGUF (sha256 checked against the pinned Hugging Face URL in the page).get_throttledwas 0x0 before and after every run; SoC temperature 45 to 51 C.Local checks (all pass): full
hugo0.130.0 extended site build (4762 pages, no errors or warnings); internal links on the 6 rendered pages of this path (145 links, 0 broken); external links in the pages resolve; pyspelling with the repo.spellcheck.ymland.wordlist.txtscoped to the path, aspell en_US (passes);tools/verify_index_fields.py(fields verified);tools/style_check.py(0 issues). The--progressstderr lines,-o jsonandsamples_nsthat the script reads are unchanged in current llama.cpp master (6868a52).Disclosure: AI assistance (Claude) drafted the pages and scripts and ran the measurements and checks on my Raspberry Pi 5. Every code block was run unchanged on the Pi, and the output blocks are pasted from that run.
Before submitting a pull request for a new Learning Path, please review Create a Learning Path
Please do not include any confidential information in your contribution. This includes confidential microarchitecture details and unannounced product information.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of the Creative Commons Attribution 4.0 International License.
Generated with Claude Code