Skip to content

fix: grid block mask applies x/y ranges both to rows - #63

Open
andrewwhitecdw wants to merge 2 commits into
NVlabs:mainfrom
andrewwhitecdw:bugfix/pose-samplers-0e7f78a4
Open

fix: grid block mask applies x/y ranges both to rows#63
andrewwhitecdw wants to merge 2 commits into
NVlabs:mainfrom
andrewwhitecdw:bugfix/pose-samplers-0e7f78a4

Conversation

@andrewwhitecdw

Copy link
Copy Markdown

This PR addresses the following issue in exts/omni.ext.mobility_gen/omni/ext/mobility_gen/pose_samplers.py: grid block mask applies x/y ranges both to rows.

Changes

  • exts/omni.ext.mobility_gen/omni/ext/mobility_gen/pose_samplers.py: grid block mask applies x/y ranges both to rows.

Details

Before:

        block_mask = np.zeros_like(mask)
        block_mask[block_x_min:block_x_min+block_size_px] = True
        block_mask[block_y_min:block_y_min+block_size_px] = True

        net_mask = block_mask & mask

After:

        block_mask = np.zeros_like(mask)
        block_mask[:, block_x_min:block_x_min+block_size_px] = True
        block_mask[block_y_min:block_y_min+block_size_px, :] = True

        net_mask = block_mask & mask

andrewwhitecdw and others added 2 commits July 27, 2026 21:05
Auditor: The change fixes the axis mix-up but still does not produce a block mask. It creates a cross-shaped mask (full columns for the x range and full rows for the y range) instead of a rectangular block. The correct fix should index both axes simultaneously: block_mask[block_y_min:block_y_min+block_size_px, block_x_min:block_x_min+block_size_px] = True.
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.

1 participant