feat: read tape_range_bias_all_max_std and log the bias std

This commit is contained in:
2026-10-30 10:58:56 +07:00
parent d51f83804d
commit b00d320094
4 changed files with 39 additions and 6 deletions

View File

@@ -529,6 +529,23 @@ TEST(TrolleyDetectionAction, LoadsPlateauFromYamlAndRejectsInvalidValue)
rig.nh.setParam(key, 0.65);
}
TEST(TrolleyDetectionAction, LoadsAllBrightBiasThresholdAndRejectsInvalidValue)
{
Rig rig;
ASSERT_TRUE(rig.loaded);
const std::string key = "actions_trolley/detect_trolley/profiles/tci_trolley_plateau/"
"tape_range_bias_all_max_std";
double value = 0.0;
ASSERT_TRUE(rig.nh.getParam(key, value));
EXPECT_DOUBLE_EQ(value, 0.02);
rig.nh.setParam(key, 0.101);
ActionRegistry invalid;
invalid.setContext(rig.ctx);
EXPECT_FALSE(invalid.loadFromConfig(rig.nh, kNamespace));
EXPECT_EQ(invalid.find("DetectTrolley"), nullptr);
rig.nh.setParam(key, 0.02);
}
TEST(TrolleyDetectionAction, RefusesToLoadWithoutASensorStore)
{
robot::NodeHandle nh;