How to get the boundary position of the top box?

How to get the boundary position of the top box like the picture bleow (blue mark) ?Thanks

2 Likes

I’m not exactly sure what you mean by “boundary position”

If those prims are labelled then you can use the bounding_box_3d_fast annotator to retrieve each prim’s transform.

The transform[3, :3] corresponds to its xyz position in world space. You can also look at the min/max for whichever axis you are interested in if you wish to get the “edge” from this view

Hi @dennis.lynch ,

Here is the bounding_box_3d annotator’s output of one of my box:

(0, # Semantic identifier which can be transformed into a readable label using the idToLabels mapping
-0.50000006, # Minimum bound in x axis in local reference frame (in world units)
-0.5000001, # Minimum bound in y axis in local reference frame (in world units)
-0.5000001, # Maximum bound in x axis in local reference frame (in world units)
0.50000006, # Maximum bound in y axis in local reference frame (in world units)
0.5, # Minimum bound in z axis in local reference frame (in world units)
0.5, # Maximum bound in z axis in local reference frame (in world units)
[[ 9.9999748e-02, -2.2479685e-04, 4.1298188e-07, 0.0000000e+00],
[ 2.2479685e-04, 9.9999748e-02, -3.2997058e-09, 0.0000000e+00],
[-4.1297341e-07, 4.2280677e-09, 1.0000000e-01, 0.0000000e+00],
[ 6.6031649e-04, -1.2652274e-03, 2.0099999e-01, 1.0000000e+00]], # Local to world transformation matrix (transforms the bounds from local frame to world frame)
0.9475 # **EXPERIMENTAL** Occlusion percentage, where 0.0 is fully visible and 1.0 is fully occluded. See additional notes below.
)

I am curious about how to get the minimum and maximum bounding box pixel coordinate in x,y,z axis from this annotation information, cause I am not really understand why the value of minimum and maximum bound in x and z axis in local reference frame (in world units) is nearly same.

Additional, Is that possible to transfer the transform[3, :3] (its xyz position in world space) to pixel coordinate?

If you can provide me the code snippets for visulizing this bounding_box_3d annotator, I will be truly appriciate, Many Thanks !!!

how can I get d 2D image annotation from bounding_box_3d.npy