Skip to content

Conversation

raelbarros
Copy link

Proposed change(s)

Adds native noise support to ray-based perception sensors.

Together these parameters let users add controlled realistic imperfection directly from the Inspector, simulating real-world sensor noise, making the system more robust.

New public fields on RayPerceptionSensorComponents:

  • DistanceNoiseStd – Adds zero-mean Gaussian noise to HitFraction, the normalised distance returned by each ray.
  • FlipHitProbability – Given probability to inverts the boolean HasHit flag of the ray (0 → 1 or 1 → 0).

Core logic implemented inside RayPerceptionSensor.ApplyNoise, called during Write() so that observations fed to the policy already include noise.

Editor updated: a Noise fold-out appears in the Inspector with the two sliders.

Docs & CHANGELOG updated accordingly. Default values 0 keep full backward compatibility.

Useful links (Github issues, JIRA tickets, ML-Agents forum threads etc.)

n/a

Types of change(s)

  • Bug fix
  • New feature
  • Code refactor
  • Breaking change
  • Documentation update
  • Other (please describe)

Checklist

  • Added tests that prove my fix is effective or that my feature works
  • Updated the changelog (if applicable)
  • Updated the documentation (if applicable)
  • Updated the migration guide (if applicable)

Other comments

@raelbarros raelbarros marked this pull request as draft July 21, 2025 14:13
@raelbarros raelbarros marked this pull request as ready for review July 21, 2025 14:14
@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ raelbarros
❌ Israel Barros


Israel Barros seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@raelbarros raelbarros closed this Sep 9, 2025
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.

2 participants