# How to get robot's pose estimation data from SLAM algorithm?

**URL:** <https://get-help.theconstruct.ai/t/how-to-get-robots-pose-estimation-data-from-slam-algorithm/12889>\
**Category:** Open Discussions\
**Tags:** rviz, gazebo, slam\
**Created:** [October 1, 2021, 5:19pm UTC](https://get-help.theconstruct.ai/t/how-to-get-robots-pose-estimation-data-from-slam-algorithm/12889 "2021-10-01T17:19:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![AmirulJ](https://get-help.theconstruct.ai/letter_avatar_proxy/v4/letter/a/dbc845/32.png) [@AmirulJ](https://get-help.theconstruct.ai/u/AmirulJ)\
**Post date:** [October 1, 2021, 5:19pm UTC](https://get-help.theconstruct.ai/t/how-to-get-robots-pose-estimation-data-from-slam-algorithm/12889/1 "2021-10-01T17:19:44Z")

</div>

I would like to do an evaluation of the localization of the robot which is pose estimation between the SLAM algorithm (gmapping package) and the ground truth. I’ve acquired the ground truth data from the `/ground_truth/state` topic and I got the data like this. I got pose.position.xyz and orientation.xyzw for the ground truth data.

![Screenshot from 2021-09-30 16-40-33](https://get-help.robotigniteacademy.com/uploads/default/original/2X/6/6511eee3d5f9950a56eb5a740a25a65bd39b15fd.png)

But now I dont know how to get the pose estimation data (robot location in the map) from the gmapping package. Where I can get the data? Is it in the `/tf` topic? If in the /tf topic which frame (`base_link` , `base_scan` , `caster_back_link` or `imu_link` ) is the estimation data from the gmapping package? And how can I echo the data in the terminal same as the ground truth data? Thank you! Figure below is the frame data from the rviz application.

![Screenshot from 2021-09-30 16-57-08](https://get-help.robotigniteacademy.com/uploads/default/original/2X/e/eb3f441813b853a3793b4384ac83780cbf8cb782.png)

---

<div class="post-metadata">

**Author:** ![m.haghbeigi](https://get-help.theconstruct.ai/letter_avatar_proxy/v4/letter/m/65b543/32.png) [@m.haghbeigi](https://get-help.theconstruct.ai/u/m.haghbeigi)\
**Post date:** [March 8, 2022, 8:35am UTC](https://get-help.theconstruct.ai/t/how-to-get-robots-pose-estimation-data-from-slam-algorithm/12889/2 "2022-03-08T08:35:52Z")

</div>

Hi,

After getting the environment map with slam\_gmapping and launching **amcl** localization, you can get the estimated position of the robot from **/amcl\_pose** topic.

Hope this helps.

---

<div class="post-metadata">

**Author:** ![AmirulJ](https://get-help.theconstruct.ai/letter_avatar_proxy/v4/letter/a/dbc845/32.png) [@AmirulJ](https://get-help.theconstruct.ai/u/AmirulJ)\
**Post date:** [May 24, 2022, 11:07am UTC](https://get-help.theconstruct.ai/t/how-to-get-robots-pose-estimation-data-from-slam-algorithm/12889/3 "2022-05-24T11:07:53Z")

</div>

thank you for your answer
