Skip to content

Potential Bug: Using Matrix Transpose Instead of Inverse Eliminates Translation in Transform Chain #48

@sally1913105

Description

@sally1913105

cur_lidar_to_ref_lidar = (curr_l2e_transform.T @

cur_lidar_to_ref_lidar = (curr_l2e_transform.T @ curr_e2g_transform.T @ ref_g2e_transform.T @ ref_e2l_transform.T)

I've noticed an issue in the transformation chain calculation where matrix transpose (.T) is used instead of proper matrix inverse (np.linalg.inv), which eliminates the translation components from the transformation.

Why this matters:

  • For rigid transformation matrices in homogeneous coordinates, the transpose is NOT equivalent to the inverse
  • Transpose only preserves rotation components but eliminates translation: [R^T 0] vs proper inverse: [R^T -R^T*t]
  • This results in transformations that maintain orientation but lose all positional information

Questions:

  1. Was this intentional or is it a bug?
  2. If intentional, what was the reasoning behind using transpose instead of inverse?
  3. The current implementation produces transformations without translation - is this the desired behavior?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions