Metatransformer report
Sensor fusion
Advanced · 65 minutes · Combine complementary measurements while preserving frames, calibration, uncertainty, and fault evidence.
Text report: images and diagrams are omitted, and links to project files are inactive. Keep the exported project alongside this PDF for wiring diagrams, models, and linked files.
Learning outcomes
- Fuse two scalar estimates using stated uncertainty assumptions.
- Identify frame, timing, bias, and correlation failures that make a fused result misleading.
Prerequisites
- vectors-frames
- filtering-estimation
Concepts
Different sensors fail differently. Wheel encoders give smooth short-term displacement but drift during slip; a camera can correct global position but may update slowly or lose features. An accelerometer reacts quickly but includes gravity and bias; a slow reference can anchor it. Fusion uses complementary information, not merely more numbers.
For two independent unbiased scalar estimates x₁ and x₂ with variances σ₁² and σ₂², inverse-variance fusion is x̂ = (x₁/σ₁² + x₂/σ₂²)/(1/σ₁² + 1/σ₂²). Its variance is 1/(1/σ₁² + 1/σ₂²). The more precise estimate receives more weight. This result depends on independence, correct uncertainty, a shared physical quantity, synchronized time, and compatible coordinates. If both estimates share the same calibration error, treating them as independent becomes overconfident.
Before combining vectors, transform them into one declared frame. A camera's right direction may not match a robot's lateral axis, and an accelerometer mounted upside down changes signs. Align timestamps or propagate older estimates forward with a model. Compute innovations—the difference between prediction and new measurement—and retain them for gating and diagnosis. The build decision may be to reject a camera update when its residual is physically implausible while continuing short-term encoder prediction and explicitly increasing uncertainty.
A common misconception is that averaging two sensors always improves accuracy. A biased sensor can pull the result away from truth; duplicated sensors exposed to the same vibration have correlated errors. Another failure is assigning tiny uncertainty because a trace looks smooth. Calibration, latency, quantization, environment, and model error all matter. Fusion should report confidence and degraded modes, not conceal disagreement. For a desk robot, stopping or slowing after prolonged localization disagreement is often sounder than trusting a polished but unsupported estimate.
Worked example
Problem
An encoder estimates travel as 1.20 m with σ = 0.10 m; a camera estimates 1.05 m with σ = 0.05 m. Assuming independent unbiased errors, compute the fused estimate.
Steps
- Weights are inverse variances: encoder 1/0.10² = 100 m⁻²; camera 1/0.05² = 400 m⁻².
- Fused value is (100×1.20 + 400×1.05)/(100+400) = 540/500 = 1.08 m.
- Fused standard deviation is √(1/500) m = 0.0447 m.
Result
The fused estimate is 1.08 m with modeled standard deviation about 0.045 m.
Sanity check
The estimate lies between inputs and closer to the more precise camera value; confidence is only slightly better than 0.05 m because the camera already dominates.
Check your understanding
Two position sensors share the same incorrectly measured scale factor. Why is naive inverse-variance fusion risky?
A. Their errors are correlated and biased B. More sensors eliminate calibration C. Variance has no units D. The fused value must equal zero
Your answer: ______________________________
Reasoning:
Answer key
ANSWER KEY — check only after attempting the question.
A. Their errors are correlated and biased
A shared scale error violates the independent, unbiased assumptions, so the calculated confidence is too optimistic and the fused estimate remains biased. More sensors do not erase shared calibration; variance does have squared units; zero is unrelated.
Hands-on lab
Goal
Fuse two position estimates and use disagreement to detect a sensor fault.
Equipment
- Toy car or sliding target
- Measured track
- Wheel/rotation counts or marked ruler readings
- Camera or second observer
- Spreadsheet or script
Procedure
- Define a common origin, positive direction, timestamps, and estimated uncertainty for both methods.
- Move through several known marks, record actual independent readings, and compute weighted fused positions.
- Plot each residual against the track reference and check whether errors appear biased or correlated.
- Deliberate fault: introduce one wheel-slip event or a fixed camera offset; diagnose it from innovation and persistent residual pattern before changing weights.
What to observe
- Expected: fusion helps when errors are roughly independent and calibrated; a shared or biased error survives.
- Measure: actual estimates, timestamps, reference positions, residuals, and chosen variances; label reference uncertainty too.
Transfer challenge
Define a degraded mode for a desk robot when encoder and camera position disagree beyond a justified threshold for three updates.
Cautions
- Use a slow, low-energy cart on a clear tabletop or floor track; do not adapt this experiment to a road vehicle.
Evidence record
Learner: ____________________ Date: ____________________
Evidence artifact or file: ____________________________________________
| Item | Record |
|---|---|
| Prediction or expected result | |
| Actual observation or measurement | |
| Conditions and tools used | |
| Difference from expectation | |
| Next decision or follow-up |
Notes: