Occupancy map is empty

i tried to acquire the occupancy map by python api, but the output is empty , i am really confused.

from omni.isaac.occupancy_map import _occupancy_map
import omni
import asyncio
_om = _occupancy_map.acquire_occupancy_map_interface()
print(
"occupanmap info: %s" % _om.__dir__()
)
_om.set_transform(
(0.0, 0.0, 3.5),(610.0, 1210.0, 3.5),(-210.0, -10.0, 0)
)
_om.update()
_om.set_cell_size(6.0)
_om.update()
_om.update()

# _om.generate()

async def generate_task(_om):
    await omni.kit.app.get_app().next_update_async()
    await omni.kit.app.get_app().next_update_async()
    await omni.kit.app.get_app().next_update_async()
    await omni.kit.app.get_app().next_update_async()
 
    # _om.generate()
    await omni.kit.app.get_app().next_update_async()
    _occupied_global_points = _om.get_occupied_positions()
    _free_global_points = _om.get_free_positions()
    _max_bounds = _om.get_max_bound()
    _min_bounds = _om.get_min_bound()
    _buffer = _om.get_buffer()
    print(
        "OccupancyMap info global map: 1pose %s \n 0pose %s buffer %s _smax_bounds %s _min_bounds %s"
        % (
            len(_occupied_global_points),
            len(_free_global_points),
            len(_buffer),
            _max_bounds,
            _min_bounds,
        )
    )
asyncio.ensure_future(generate_task(_om))

here is the output:

occupanmap info: ['__init__', '__doc__', '__module__', 'generate', 'update', 'set_transform', 'set_cell_size', 'get_occupied_positions', 'get_free_positions', 'get_min_bound', 'get_max_bound', 'get_dimensions', 'get_buffer', 'get_colored_byte_buffer', '__new__', '__repr__', '__hash__', '__str__', '__getattribute__', '__setattr__', '__delattr__', '__lt__', '__le__', '__eq__', '__ne__', '__gt__', '__ge__', '__reduce_ex__', '__reduce__', '__subclasshook__', '__init_subclass__', '__format__', '__sizeof__', '__dir__', '__class__']
OccupancyMap info global map: 1pose 0 
 0pose 0 buffer 0 _smax_bounds (0,0,0) _min_bounds (0,0,0)

Thanks!

sorry , I have find the wrong code. the set_transform function index is (origin, lower_bound, upper_bound).
It works now .

Please help me close this conversation, thanks !