Skip to content

docs: clarify that Obstacle length_m is half the longitudinal size - #213

Open
HarshRajSinghania wants to merge 1 commit into
ShisatoYano:mainfrom
HarshRajSinghania:fix/obstacle-length-docstring
Open

HarshRajSinghania wants to merge 1 commit into
ShisatoYano:mainfrom
HarshRajSinghania:fix/obstacle-length-docstring

Conversation

@HarshRajSinghania

Copy link
Copy Markdown

Summary

Updates the constructor docstring in src/components/obstacle/obstacle.py so that length_m is correctly described as half the obstacle's longitudinal size, matching the existing description for width_m and the actual contour construction (±length_m).

Motivation

Fixes #212. The previous docstring claimed length_m was the full longitudinal size, which is inconsistent with how the outline is built and with the half-size semantics already documented for width_m. Example usage in doc/sensors/visualize_obstacle.py produces a rectangle twice the size of the documented parameters.

Implementation

  • Changed only the length_m parameter description in the __init__ docstring from "Obstacle's longitudinal size[m]" to "Half of the obstacle's longitudinal size[m]".
  • No code behavior, defaults, or other documentation changed.

Testing

  • Verified the change is limited to the docstring (diff is a single line).
  • Confirmed the contour construction still uses ±length_m / ±width_m as before.
  • No unit tests exist for this class; the change is documentation-only and does not affect runtime behavior.

Closes #212.

Fixes ShisatoYano#212. The constructor docstring for length_m previously described it as the full longitudinal size, but the outline is built from ±length_m, matching the half-size semantics already documented for width_m. No behavior change.

This branch has not been deployed

No deployments
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.

Obstacle's docstring says length_m is the full length, but it is half of it

1 participant