mirage.orbit.orbit_file_publisher.OrbitFilePublisher#
- class mirage.orbit.orbit_file_publisher.OrbitFilePublisher(data_write_dir)#
Bases:
XEmbodyPublisher
Orbit specific file publisher that works with the ROS publishing code
- __init__(data_write_dir) None #
Initializes the publisher code. :param data_write_dir: The directory to write the data to.
Methods
__init__
(data_write_dir)Initializes the publisher code.
get_inpainted_image
(blocking)Gets the inpainted image.
publish_to_ros_node
(rgb_image, point_cloud, ...)Publishes the RGB image, segmentation mask, and joint angles to the ROS2 node.
- get_inpainted_image(blocking: bool) array #
Gets the inpainted image. :param blocking: Whether to block until the inpainted image is received. :return: The inpainted image.
- publish_to_ros_node(rgb_image: array, point_cloud: array, segmentation_mask: array, joint_angles: array)#
Publishes the RGB image, segmentation mask, and joint angles to the ROS2 node. :param rgb_image: The RGBD image 4 channel numpy. :param point_cloud: The point cloud 3 channel numpy. :param segmentation_mask: The segmentation mask 1 channel numpy. :param joint_angles: The joint angles 1D numpy.