NuCon/nucon
Dominik Roth 6cb93ad56d feat: abort trajectory on high kNN uncertainty in simulator
NuconSimulator now accepts uncertainty_threshold (default None = disabled).
When set and using a kNN model, _update_reactor_state() calls
forward_with_uncertainty() and raises HighUncertaintyError if the GP
posterior std exceeds the threshold.

NuconEnv and NuconGoalEnv catch HighUncertaintyError in step() and
return truncated=True, so SB3 bootstraps the value rather than treating
OOD regions as terminal states.

Usage:
    simulator = NuconSimulator(uncertainty_threshold=0.3)
    # episodes are cut short when the policy wanders OOD

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-12 18:29:54 +01:00
..
drake_assets Impl drake 2024-10-03 23:25:53 +02:00
__init__.py Dev and simulator fixes 2026-03-12 16:27:48 +01:00
core.py Add valve API, cheat_mode, and write-only param fixes 2026-03-12 17:16:08 +01:00
drake.py Fix typo in meme 2024-10-03 23:28:29 +02:00
model.py fix: retry game connection in __init__ as well as collect_data 2026-03-12 17:53:35 +01:00
rl.py feat: abort trajectory on high kNN uncertainty in simulator 2026-03-12 18:29:54 +01:00
sim.py feat: abort trajectory on high kNN uncertainty in simulator 2026-03-12 18:29:54 +01:00