Repository navigation
eval: score the calculator against measured M100 flight energy - #260
Merged
Merged
Conversation
The mission pack's expected values come from the calculator, so it cannot say whether the calculator matches real flights. This adds a reality-check track that scores assess_mission against battery energy measured on 209 DJI Matrice 100 flights (CMU, CC BY 4.0, DOI 10.1184/R1/12683453.v1). - eval/datasets: manifest with license provenance and size/MD5/SHA-256 pins, an https-only fetcher, and a deriver that reduces the record to a committed, pinned one-row-per-flight table with attribution. - suas/eval/flight_energy.py: motor-on window, body-to-world velocity rotation, phase classification on from_log's thresholds, trapezoid energy. - suas/eval/reality.py: unladen calibration corrected to ISA sea level, laden flights scored held out through the real assess_mission, calm and surface wind inputs, required-reserve and Wilson-interval summaries, time/power split, fitted mass exponent. - eval/reality_check.py: report-only CI step; a missing or tampered table fails it. Results go to eval/reality/, not eval/results/, which build_leaderboard reads as provider reports. Finding (eval/REALITY.md): with calm input the calculator under-predicts 127 of 128 held-out flights by 13.1% on average; 21 need more than the 20% reserve, all at 10 to 12 m/s. The gap is unmodeled maneuvering time (1.23x), not power (0.93x). The calculator itself is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RvN6zzAfs65mmc2vrFCP83
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RvN6zzAfs65mmc2vrFCP83
MatthewK84
pushed a commit
that referenced
this pull request
Dec 4, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RvN6zzAfs65mmc2vrFCP83 # Conflicts: # backend/suas/eval/flight_energy.py # backend/tests/test_flight_energy.py # eval/datasets/derive_m100.py # eval/datasets/derived/README.md # eval/datasets/derived/m100_flights.csv # eval/datasets/manifest.json
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.
Adds a reality-check track. It compares the calculator's energy figure with battery energy measured on real flights. Every other eval score is measured against the calculator, whose output is the mission pack's expected values. So until now nothing in
eval/could say whether the calculator matches the world.The data is the CMU DJI Matrice 100 package-delivery record: 209 flights with logged voltage, current, position, orientation and anemometer. It is Rodrigues et al., Scientific Data 8, 155 (2021), DOI 10.1184/R1/12683453.v1, CC BY 4.0.
What it found
Full writeup:
eval/REALITY.md. Every figure there citeseval/reality/2026-12-04/m100.json.distance / speedhas no term for the acceleration, braking and turning at each waypoint.What changed
eval/datasets/(new):manifest.jsonrecords the license (read from the publisher's record, with date and source) and pins every fetched file by size, MD5 and SHA-256.fetch.pyis standard library only, https-only (redirects included), and retries.derive_m100.pyreduces the record toderived/m100_flights.csv: one row per flight, committed and pinned by SHA-256, with attribution and the changes made beside it inderived/README.md. CI never downloads.backend/suas/eval/flight_energy.py(new, pure). It finds the motor-on window and rotates body-frame velocity into the world frame by the logged quaternion. Phases are classified onsuas.calculations.from_log's thresholds, with a ground rule so post-landing idle is not counted as hover. Energy is integrated by the trapezoid rule.backend/suas/eval/reality.py(new). Calibration uses only unladen flights: hover from the four hover tests, cruise from 66 unladen route flights, both corrected to ISA sea level. The 128 laden flights are scored held out through the realassess_mission, on an airframe built in memory. The report gives:eval/reality_check.py(new). This is the CLI (--json,--write,--date). Results go toeval/reality/<date>/, noteval/results/, becausebuild_leaderboardreads every directory there as provider reports.Reality checkstep in the backend job, on Python 3.12 only, writes its summary to the job summary. No finding fails it. A missing table, a table that differs from its pin, or a row that does not parse does fail it.EvalDataErrorinsuas/errors.py.eval/datasets/.cache/is git-ignored and skipped by the US English lint.docs/engineering-practices.mdanddocs/PLAN-90.mdentries.What stays the same
CALCULATOR_VERSIONstays 1.9.1. Adding a maneuvering term would bump it and regenerate the pack, which is a decision for its own PR, informed by this one.aircraft.json. Nothing here changes a catalog field.How it was checked
fit_exponentrecovers a known exponent.fetch.pyagainst the live hosts: a second run verified every hash and downloaded nothing.suasmodules are at 100%.mypy --strict.Limits
Generated by Claude Code