Skip to content

Log noise type and value of each of the sensor components - #314

Merged
saikishor merged 2 commits into
mainfrom
log/sensor_component/noise_type_and_value
Sep 30, 2026
Merged

saikishor merged 2 commits into
mainfrom
log/sensor_component/noise_type_and_value

Conversation

@saikishor

Copy link
Copy Markdown
Member

Description

Logs the type of ssensor noise and the noise value of each component. This helps to see if the changes are relfected.


[ros2_control_node-7] [INFO] [1790438111.882314555] [MujocoSystemInterface]: Sensor component 'torso_imu_sensor_quat' is using 'uniform' noise with stddev: 0.001000
[ros2_control_node-7] [INFO] [1790438111.882319321] [MujocoSystemInterface]: Sensor component 'torso_imu_sensor_gyro' is using 'uniform' noise with stddev: 0.001500
[ros2_control_node-7] [INFO] [1790438111.882322751] [MujocoSystemInterface]: Sensor component 'torso_imu_sensor_accel' is using 'uniform' noise with stddev: 0.020000

Is this user-facing behavior change?

NO

Did you use Generative AI?

Logic simplification, Claude Sonnet

@codecov-commenter

codecov-commenter commented Sep 26, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 62.50000% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.70%. Comparing base (58f465b) to head (e6bc261).

Files with missing lines Patch % Lines
...ujoco_ros2_control/src/mujoco_system_interface.cpp 40.00% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #314      +/-   ##
==========================================
- Coverage   82.73%   82.70%   -0.03%     
==========================================
  Files          35       35              
  Lines        5896     5904       +8     
  Branches      601      602       +1     
==========================================
+ Hits         4878     4883       +5     
- Misses        698      701       +3     
  Partials      320      320              
Flag Coverage Δ
unittests 82.70% <62.50%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...ros2_control/include/mujoco_ros2_control/utils.hpp 74.41% <100.00%> (+1.91%) ⬆️
...ujoco_ros2_control/src/mujoco_system_interface.cpp 59.80% <40.00%> (-0.10%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

ndunkelb-nasa
ndunkelb-nasa previously approved these changes Sep 27, 2026

@ndunkelb-nasa ndunkelb-nasa left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks pretty straightforward! Just one question about the use of the to_string(), otherwise good to go.

Comment on lines +90 to +93
inline const char* to_string(NoiseDistribution distribution)
{
return distribution == NoiseDistribution::kUniform ? "uniform" : "gaussian";
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this planned to be re-used elsewhere? Seems kind of silly to have a one-liner function to just be used in one place which could just have the original implementation.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Truee, right now no plans to use in atleast

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can modify it. Thanks

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@saikishor
saikishor enabled auto-merge (squash) September 30, 2026 18:59
@saikishor
saikishor disabled auto-merge September 30, 2026 18:59
@saikishor
saikishor merged commit 7515da0 into main Sep 30, 2026
15 checks passed
@saikishor
saikishor deleted the log/sensor_component/noise_type_and_value branch September 30, 2026 19:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants