Closed hmpcjayaweera closed 1 year ago
can you paste the launch file you are using?
And also paste the screenshot of the output for ros2 topic list when the entire pipeline is running?
If you are seeing the frame, it seems like localization is working, but the topic you are looking at might be wrong. For example we remap the /localization_result topic to /initialpose in the Nav2 Isaac Sim launch file.
Rviz2 as in step 7 of https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_map_localization/blob/main/README.md#quickstart. Panels:
isaac_ros_occupancy_grid_localizer_quickstart.launch.py for step 9
import os
from ament_index_python.packages import get_package_share_directory
from launch import LaunchDescription from launch.actions import GroupAction from launch_ros.actions import ComposableNodeContainer from launch_ros.actions import Node from launch_ros.descriptions import ComposableNode
def generate_launch_description():
lifecycle_nodes = ['map_server']
map_yaml_path_dir = os.path.join(
get_package_share_directory('isaac_ros_occupancy_grid_localizer'), 'maps', 'map.yaml')
occupancy_grid_localizer_node = ComposableNode(
package='isaac_ros_occupancy_grid_localizer',
plugin='nvidia::isaac_ros::occupancy_grid_localizer::OccupancyGridLocalizerNode',
name='occupancy_grid_localizer',
parameters=[map_yaml_path_dir, {
'loc_result_frame': 'map',
'map_yaml_path': map_yaml_path_dir,
}])
occupancy_grid_localizer_container = ComposableNodeContainer(
package='rclcpp_components',
name='occupancy_grid_localizer_container',
namespace='',
executable='component_container_mt',
composable_node_descriptions=[
occupancy_grid_localizer_node,
],
output='screen'
)
# Seting transform between lidar_frame and base_link
# since Isaac Sim does not set this transform
baselink_lidar_publisher = Node(
package='tf2_ros', executable='static_transform_publisher',
output='screen',
arguments=['0.0', '0.0', '0.0', '0.0', '0.0', '0.0', 'base_link',
'lidar_frame'])
load_nodes = GroupAction(
actions=[
Node(
package='nav2_map_server',
executable='map_server',
name='map_server',
output='screen',
respawn_delay=2.0,
parameters=[{'yaml_filename': map_yaml_path_dir}]),
Node(
package='nav2_lifecycle_manager',
executable='lifecycle_manager',
name='lifecycle_manager_localization',
output='screen',
parameters=[{'use_sim_time': False},
{'autostart': True},
{'node_names': lifecycle_nodes}])
]
)
# Create the launch description and populate
ld = LaunchDescription([occupancy_grid_localizer_container,
baselink_lidar_publisher])
# Add the actions to launch all of the localiztion nodes
ld.add_action(load_nodes)
return ld
besides I have used ros2 service call trigger_grid_search_localization std_srvs/srv/Empty {} and ros2 launch isaac_ros_pointcloud_utils isaac_ros_laserscan_to_flatscan.launch.py
In addtion the launch file for neo MPO-700 (for gazebo ros2 humble)
Can you send the screenshot for the output for ros2 topic list also.
Also can you confirm that you are running ros2 topic echo /localization_result
before running ros2 service call trigger_grid_search_localization std_srvs/srv/Empty {}
?
Hi, when i try to run the rviz2 (in step 7 - https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_map_localization/blob/main/README.md#quickstart) and then run the step 9, I got this error, [ERROR] [1686091364.713581586] [rviz2]: Vertex Program:rviz/glsl120/indexed_8bit_image.vert Fragment Program:rviz/glsl120/indexed_8bit_image.frag GLSL link result : active samplers with a different type refer to the same texture image unit
Previously it was working, but suddenly I got this, please can you help me.
I do not believe the "[ERROR] [1686091364.713581586] [rviz2]: Vertex Program:rviz/glsl120/indexed_8bit_image.vert Fragment Program:rviz/glsl120/indexed_8bit_image.frag GLSL link result :" is related to the isaac_ros_map_localization package. To discuss that please open an issue with rviz
Please can I know how to make the map (.yaml and .png) files. Can I make it using SLAM Toolbox (slam tool box gives .yaml and pgm, can i use any converter to convert this .pgm to png and use for Isaac ROS map localization package ).
yes you can use the map generated using SLAM Toolbox. As you said, convert the .pgm to .png and use it with isaac_ros_map_localization.
Are you able to echo the /localization_result
topic?
still not, will let you soon
![Screenshot from 2023-06-08 12-50-11](https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_map_localization/assets/48442332/c10573e9-a795-43b1-8864-9da13fd2c ![Screenshot from 2023-06-08 12-49-23](https://github.com/N VIDIA-ISAAC-ROS/isaac_ros_map_localization/assets/48442332/beb42a86-ceda-4f3e-8516-666c3d53e446) c17) the ros2 topic echo /localization_result is not publishing any value
For the ros2 topic echo /flatscan, I got "The message type 'isaac_ros_pointcloud_interfaces/msg/FlatScan' is invalid", Is this possible. Thank you
Once I Trigger the localization using a command line service call :ros2 service call trigger_grid_search_localization std_srvs/srv/Empty {}, the three axis appear as attached photo (seems robot in the same position of the map in Gazebo). However, when I check the base_link, it is in the (0,0) of the map.
Hi, Robot - MPO-700 Simulation environment - Gazebo + ROS2 Humble
I have follow the below steps to use the Isaac ROS Map localization for the robot in Gazebo and ROS2, however, the robot model is not shown in the rviz and the "ros2 topic echo /localization_result" not give any value. It only shows that three-axis is localized (3-axis in the correct position of the rviz)
Please help me to solve this problem. Thanks.