# Get SLAM Trajectory Position and Orientation in Python

**URL:** <https://discourse.paraview.org/t/get-slam-trajectory-position-and-orientation-in-python/15971>\
**Category:** LidarView, Lidar, and SLAM\
**Created:** [January 12, 2025, 6:20pm UTC](https://discourse.paraview.org/t/get-slam-trajectory-position-and-orientation-in-python/15971 "2025-01-12T18:20:10Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Gatien\_Ferret](https://discourse.paraview.org/user_avatar/discourse.paraview.org/gatien_ferret/32/9789_2.png) [@Gatien\_Ferret](https://discourse.paraview.org/u/Gatien_Ferret)\
**Post date:** [January 15, 2025, 12:44pm UTC](https://discourse.paraview.org/t/get-slam-trajectory-position-and-orientation-in-python/15971/2 "2025-01-15T12:44:19Z")

</div>

Hi @figbar ,

You need first to retrieve the Client Side Object, then you can access to the outputs, so the python scripting for doing this would be the following :

```auto
slam_online = FindSource("SLAMonline1")
slam_cso = slam_online.GetClientSideObject()
traj = slam_cso.GetOutput(1) # the trajectory is the second output of the SLAM filter

```

You may also want to have a look at [this](https://gitlab.kitware.com/LidarView/lidarview-core/-/blob/master/Examples/Python/UsePythonAnimations.md) regarding animations in LidarView

And in particular this [example](https://gitlab.kitware.com/LidarView/lidarview-core/-/blob/master/Examples/Python/animation_focus_last_pose.py)

Hope this helps,

Gatien

---

_[View the full topic](https://discourse.paraview.org/t/get-slam-trajectory-position-and-orientation-in-python/15971)._
