Sanja, <div>Is your crash repeatable?  Does it happen at startup?  Consistently with the same data?   Is there any chance you could make a bag file with test code which I could debug?  The only data manipulation within that method is a find on an std::map<std::string, unsigned int> and it happens with a protective lock for thread safety.  </div>


<div><br></div><div>Tully</div><br><div class="gmail_quote">On Fri, Jul 30, 2010 at 10:38 AM, Sanja Popovic <span dir="ltr"><<a href="mailto:sanja@mit.edu" target="_blank">sanja@mit.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


This is the value of the point before the transformation:<br>
header:<br>
    seq: 92<br>
    stamp: 1280425929.966004043<br>
    frame_id: /base_footprint<br>
  point:<br>
    x: 0.72556<br>
    y: -0.186542<br>
    z: 0.690001<br>
<br>
I am running only pcl from the trunk (I had some problems with the visualizer, as you can see from the mails yesterday...). Even if I get rid of the visualizations and don't run anything from trunk, I still have the same problem.<br>



<br>
The function I'm calling the TF from has PC2 as a parameter, but I transform it to PCL PointCloud, but that still doesn't affect the TF because I make the stamped points separately. The header comes from the PCL PointCloud header and the coordinates are set based on data from the PC.<br>



________________________________________<br>
From: Radu Bogdan Rusu [<a href="mailto:rusu@willowgarage.com" target="_blank">rusu@willowgarage.com</a>]<br>
Sent: Friday, July 30, 2010 1:23 PM<br>
To: <a href="mailto:ros-users@code.ros.org" target="_blank">ros-users@code.ros.org</a><br>
Cc: Sanja Popovic<br>
Subject: Re: [ros-users] Transforming point gives segmentation fault<br>
<div><div></div><div><br>
Hehe, no worries about the spam. Can you check the values of your points just to be sure? Also, is this a clean setup?<br>
Aaaand also, I see some sensor_msgs::PointCloud2 references in there. I don't think TF supports PC2 natively yet (Tully<br>
- ?), unless you go through pcl_tf.<br>
<br>
CHeers,<br>
Radu.<br>
<br>
On 07/30/2010 10:20 AM, Sanja Popovic wrote:<br>
> Hi,<br>
><br>
> Sorry for the spam today, but I'm having lots of problems with ROS.<br>
><br>
> I want to transform a point using a tf, but I keep getting the segmentation fault. Here is the backtrace from the gdb:<br>
><br>
> Program received signal SIGSEGV, Segmentation fault.<br>
> 0xb78155de in tf::Transformer::lookupFrameNumber(std::string const&) const () from /opt/ros/cturtle/stacks/geometry/tf/lib/libtf.so<br>
> (gdb) bt<br>
> #0  0xb78155de in tf::Transformer::lookupFrameNumber(std::string const&) const () from /opt/ros/cturtle/stacks/geometry/tf/lib/libtf.so<br>
> #1  0xb780da37 in tf::Transformer::lookupTransform(std::string const&, std::string const&, ros::Time const&, tf::StampedTransform&) const ()<br>
>     from /opt/ros/cturtle/stacks/geometry/tf/lib/libtf.so<br>
> #2  0xb780e87a in tf::Transformer::transformPoint(std::string const&, tf::Stamped<btVector3>  const&, tf::Stamped<btVector3>&) const ()<br>
>     from /opt/ros/cturtle/stacks/geometry/tf/lib/libtf.so<br>
> #3  0xb781647b in tf::TransformListener::transformPoint(std::string const&, geometry_msgs::PointStamped_<std::allocator<void>  >  const&, geometry_msgs::PointStamped_<std::allocator<void>  >&) const () from /opt/ros/cturtle/stacks/geometry/tf/lib/libtf.so<br>



> #4  0x080662e2 in callback (cloudMessage=...) at /opt/ros/cturtle/stacks/lis/bookbot/src/tableFilter.cpp:253<br>
> #5  0x0807c285 in boost::detail::function::void_function_invoker1<void (*)(sensor_msgs::PointCloud2_<std::allocator<void>  >), void, sensor_msgs::PointCloud2_<std::allocator<void>  >  >::invoke (function_ptr=..., a0=...) at /usr/include/boost/function/function_template.hpp:112<br>



> #6  0x0807d58c in boost::function1<void, sensor_msgs::PointCloud2_<std::allocator<void>  >  >::operator() (this=0x8116148, params=...)<br>
>      at /usr/include/boost/function/function_template.hpp:1013<br>
> #7  ros::SubscriptionCallbackHelperT<sensor_msgs::PointCloud2_<std::allocator<void>  >, void>::call (this=0x8116148, params=...)<br>
>      at /opt/ros/cturtle/ros/core/roscpp/include/ros/subscription_callback_helper.h:173<br>
> #8  0xb7416fbb in ros::SubscriptionQueue::call (this=0x8118c48) at /opt/ros/cturtle/ros/core/roscpp/src/libros/subscription_queue.cpp:164<br>
> #9  0xb74593fa in ros::CallbackQueue::callOneCB (this=0x810c7e8, tls=0x81189a8) at /opt/ros/cturtle/ros/core/roscpp/src/libros/callback_queue.cpp:381<br>
> #10 0xb745a25f in ros::CallbackQueue::callAvailable (this=0x810c7e8, timeout=...) at /opt/ros/cturtle/ros/core/roscpp/src/libros/callback_queue.cpp:333<br>
> #11 0xb745e1e0 in ros::SingleThreadedSpinner::spin (this=0xbffff12c, queue=0x810c7e8) at /opt/ros/cturtle/ros/core/roscpp/src/libros/spinner.cpp:49<br>
> #12 0xb73e96d9 in ros::spin (s=...) at /opt/ros/cturtle/ros/core/roscpp/src/libros/init.cpp:493<br>
> #13 0xb73e9709 in ros::spin () at /opt/ros/cturtle/ros/core/roscpp/src/libros/init.cpp:488<br>
> #14 0x080650eb in listener (n=...) at /opt/ros/cturtle/stacks/lis/bookbot/src/tableFilter.cpp:269<br>
> #15 0x08066fa5 in main (argc=1, argv=0xbffff454) at /opt/ros/cturtle/stacks/lis/bookbot/src/tableFilter.cpp:276<br>
><br>
> The call of function is nothing fancy, just tfListener->transformPoint(frame, point1, point2) where frame is a string and points 1 and 2 are PointStamped. tfListener is a global pointer to a transformListener in the code.<br>



><br>
> Thanks a lot,<br>
> Sanja<br>
> _______________________________________________<br>
> ros-users mailing list<br>
> <a href="mailto:ros-users@code.ros.org" target="_blank">ros-users@code.ros.org</a><br>
> <a href="https://code.ros.org/mailman/listinfo/ros-users" target="_blank">https://code.ros.org/mailman/listinfo/ros-users</a><br>
<br>
--<br>
| Radu Bogdan Rusu | <a href="http://rbrusu.com/" target="_blank">http://rbrusu.com/</a><br>
_______________________________________________<br>
ros-users mailing list<br>
<a href="mailto:ros-users@code.ros.org" target="_blank">ros-users@code.ros.org</a><br>
<a href="https://code.ros.org/mailman/listinfo/ros-users" target="_blank">https://code.ros.org/mailman/listinfo/ros-users</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Tully Foote<br>Systems Engineer<br>Willow Garage, Inc.<br><a href="mailto:tfoote@willowgarage.com" target="_blank">tfoote@willowgarage.com</a><br>(650) 475-2827<br>