Files
ruvnet--RuView/v2/crates/ruview-swarm/Cargo.toml
T
rUv 8d64434d21 feat(swarm): ADR-149 evaluation harness — GDOP, IQM+bootstrap CI, noise sweep (#875)
Stage-1 kinematic evaluator per ADR-149 (peer-reviewed). Pure Rust, no new deps.

evals/:
- gdop.rs: 2D Geometric Dilution of Precision ((HᵀH)⁻¹ trace-sqrt); None for
  <2 observers or collinear/singular geometry
- stats.rs: IQM (Agarwal 2021) + 95% stratified-bootstrap CI (deterministic LCG)
  + probability_of_improvement
- metrics.rs: EpisodeMetrics + AggregateMetrics::from_strata (IQM±CI, seed-stratified)
- runner.rs: seeded kinematic rollout (FlightPattern-driven), seed×episode matrix,
  3σ×3κ default noise sweep (Gaussian amplitude × von Mises phase)
- report.rs + eval_swarm bin: generates evals/RESULTS.md leaderboard

RESULTS.md surfaces the real coverage-vs-localization-precision trade-off via GDOP:
partitioned wins coverage (100%) but single-drone sightings (GDOP 0 → 7.0m);
pheromone gets multistatic fusion (GDOP 1.6 → 4.1m). Wi2SAR 5m paper-baseline row included.

Stage-2 (Gazebo/PX4 SITL false-alarm + collision on median seeds) is documented follow-on.

Tests: 116 default / 133 full+train (+13 eval tests), 0 failed. Clippy clean (-D warnings).
2026-05-30 17:38:49 -04:00

85 lines
2.5 KiB
TOML

[package]
name = "ruview-swarm"
version = "0.1.0"
edition = "2021"
description = "RuView drone swarm control system — hierarchical-mesh topology, Raft consensus, MARL, CSI sensing integration (ADR-148)"
license = "Apache-2.0"
# Publishing disabled until: (1) PR #862 merges, (2) internal path-deps are
# published in dependency order, (3) export-control sign-off on the ITAR-gated
# coordination features (USML Category VIII(h)(12)). Flip to true deliberately.
publish = false
[features]
default = []
# ITAR/USML Category VIII(h)(12): swarming coordination features.
# Must not be enabled in international distributions without export counsel review.
itar-unrestricted = []
mavlink = ["dep:mavlink"]
ros2-dds = []
onnx = ["dep:ort"]
simulation = []
demo = ["simulation"]
full = ["mavlink", "onnx", "demo", "itar-unrestricted"]
ruflo = ["dep:reqwest", "dep:serde_json"]
# Heavy GPU-capable MARL training (real Candle autodiff PPO). Off by default so
# the default build stays light and the existing test suite keeps passing.
train = ["dep:candle-core", "dep:candle-nn"]
cuda = ["candle-core/cuda", "candle-nn/cuda"]
[dependencies]
wifi-densepose-core = { path = "../wifi-densepose-core" }
# Serialization
serde = { version = "1", features = ["derive"] }
serde_json = { version = "1", optional = true }
toml = "0.8"
# Async runtime
tokio = { version = "1", features = ["full"] }
async-trait = "0.1"
# MAVLink v2 (optional)
mavlink = { version = "0.13", optional = true }
# ONNX Runtime (optional — for MARL actor inference)
ort = { version = "2.0.0-rc.11", optional = true }
# Candle 0.9 — real autodiff PPO training (optional, behind `train` feature).
candle-core = { version = "0.9", default-features = false, optional = true }
candle-nn = { version = "0.9", default-features = false, optional = true }
# HTTP client (optional — for Ruflo HTTP backend)
reqwest = { version = "0.12", features = ["json"], optional = true }
# Crypto — MAVLink v2 HMAC-SHA256 signing
hmac = "0.12"
sha2 = "0.10"
# Error handling
thiserror = "2.0"
# Logging
tracing = "0.1"
# Numerics
nalgebra = "0.33"
rand = "0.8"
[dev-dependencies]
criterion = { version = "0.5", features = ["html_reports"] }
tokio-test = "0.4"
[[bench]]
name = "swarm_bench"
harness = false
# MARL training binary — requires the `train` feature (Candle autodiff).
# Excluded from the default build so `cargo test`/CI stay light.
[[bin]]
name = "train_marl"
required-features = ["train"]
# ADR-149 Stage-1 evaluation CLI — pure Rust, no special feature needed.
[[bin]]
name = "eval_swarm"