[ros-users] image_proc doesn't work with camera1394

Jeremy Leibs leibs at willowgarage.com
Sat Mar 27 16:30:04 UTC 2010


Someone that knows more about this can probably help, however I've
seen something like this before.

I believe that image_proc does not actually do it's subscription /
processing anything until something subscribes to one of the topics
that it's producing.

This is mentioned in the image_proc documentation:

"All processing is on demand. Color processing is performed only if
there is a subscriber to a color topic. Rectification is performed
only if there is a subscriber to a rectified topic. While there are no
subscribers to output topics, image_proc unsubscribes from the
image_raw and camera_info topics."

This is "nice" in that it doesn't consume unnecessary CPU processing
images that nobody cares about (in turn since it's not subscribed to
the camera, the camera doesn't actually have to be streaming data
either if the driver were smart).  But, it's also very confusing in
that it appears that it's not working until you actually subscribe.

Do you have a downstream node subscribed to one of the processed image topics?

--Jeremy

On Sat, Mar 27, 2010 at 6:26 AM, Jack O'Quin <jack.oquin at gmail.com> wrote:
> On Thu, Mar 25, 2010 at 6:35 PM, Eric Perko <wisesage5001 at gmail.com> wrote:
>> Hi all,
>>
>> I'm currently trying to use the ROS image_pipeline and the new
>> camera1394 driver to get some Point Grey 1394 cameras up and running.
>> For some reason, I am unable to view any of the topic being published
>> by image_proc. First, here is the launch file I am using to start up
>> the camera and image_proc:
>>
>> <launch>
>> <node pkg="camera1394" type="camera1394" name="left">
>> <param name="guid" value="00b09d010061ab25" />
>> <param name="video_mode" value="640x480_rgb" />
>> <param name="camera_info_manager/url"
>> value="file:///home/eric/code/cwrucam/cwrucam/calibration/calibration_left.yaml"
>> />
>> </node>
>> <node pkg="image_proc" type="image_proc" name="proc" ns="left/camera" />
>> </launch>
>>
>> After running this, I get the following output from rostopic list -v:
>>
>> Published topics:
>>  * /left/camera/image_rect_color [sensor_msgs/Image] 1 publisher
>>  * /left/camera/image_rect [sensor_msgs/Image] 1 publisher
>>  * /left/camera/camera_info [sensor_msgs/CameraInfo] 1 publisher
>>  * /rosout [roslib/Log] 2 publishers
>>  * /left/camera/image_raw [sensor_msgs/Image] 1 publisher
>>  * /rosout_agg [roslib/Log] 1 publisher
>>  * /left/camera/image_color [sensor_msgs/Image] 1 publisher
>>  * /left/camera/image_mono [sensor_msgs/Image] 1 publisher
>>
>> Subscribed topics:
>>  * /clock [unknown type] 3 subscribers
>>  * /rosout [roslib/Log] 1 subscriber
>>
>> So, based on that, I can see that the image_proc node is actually up
>> and running. I am able to do "rosrun image_view image_view
>> image:=/left/camera/image_raw" and see the color image from my camera
>> streaming in. rostopic hz also confirms that both
>> /left/camera/image_raw and /left/camera/camera_info are running at
>> about 15 fps.
>>
>> Now, when I run "rosrun image_view image_view
>> image:=/left/camera/image_rect_color" (or any other image_proc
>> published topic), I get a blank window with no image in it. Running
>> rostopic list -v again while the image_view node is running gives me
>> the following:
>>
>> Published topics:
>>  * /left/camera/image_rect_color [sensor_msgs/Image] 1 publisher
>>  * /left/camera/image_rect [sensor_msgs/Image] 1 publisher
>>  * /left/camera/camera_info [sensor_msgs/CameraInfo] 1 publisher
>>  * /rosout [roslib/Log] 3 publishers
>>  * /left/camera/image_raw [sensor_msgs/Image] 1 publisher
>>  * /rosout_agg [roslib/Log] 1 publisher
>>  * /left/camera/image_color [sensor_msgs/Image] 1 publisher
>>  * /left/camera/image_mono [sensor_msgs/Image] 1 publisher
>>
>> Subscribed topics:
>>  * /left/camera/image_rect_color [sensor_msgs/Image] 1 subscriber
>>  * /clock [unknown type] 4 subscribers
>>  * /left/camera/camera_info [sensor_msgs/CameraInfo] 1 subscriber
>>  * /rosout [roslib/Log] 1 subscriber
>>  * /left/camera/image_raw [sensor_msgs/Image] 1 subscriber
>>
>> So, I can see that image_proc is subscribing to the correct topics and
>> image_view is also on the correct topic. I also tried starting the
>> image_proc node from the command line as indicated at
>> http://www.ros.org/wiki/image_proc but got the exact same behavior as
>> with the launch file. In either case, rostopic hz
>> /left/camera/image_rect_color just outputs that it is subscribing to
>> the topic and waits.
>
>> So, I'm a bit stumped as to what to do to narrow down what is causing
>> this behavior, since I get no error output in any of my terminal
>> windows. I'm running the latest based on these .rosinstall files:
>> http://ros.org/rosinstalls/latest_pr2.rosinstall with
>> http://www.ros.org/rosinstalls/wg_latest_devel.rosinstall in an
>> overlay.
>>
>> Are there some steps I can take to try to debug this problem? Has
>> anyone else experienced this type of issue with the new camera1394
>> driver?
>
> I am seeing similar problems. I tried it briefly yesterday, but did
> not have time to dig very deeply. Here is a follow-up report on where
> I am so far...
>
> On my system, image_proc is *not* subscribing to the image_raw output
> from the driver. The image_view node *does* subscribe and works fine.
>
> joq at vision-4:~$ rosnode info /test_camera/camera/image_proc_1269693701464224000
> --------------------------------------------------------------------------------
> Node [/test_camera/camera/image_proc_1269693701464224000]
>
> Publications:
>  * /rosout [roslib/Log]
>  * /test_camera/camera/image_mono [sensor_msgs/Image]
>  * /test_camera/camera/image_rect/compressed [sensor_msgs/CompressedImage]
>  * /test_camera/camera/image_mono/compressed [sensor_msgs/CompressedImage]
>  * /test_camera/camera/image_color/compressed [sensor_msgs/CompressedImage]
>  * /test_camera/camera/image_mono/theora [theora_image_transport/packet]
>  * /test_camera/camera/image_rect [sensor_msgs/Image]
>  * /test_camera/camera/image_rect_color/theora [theora_image_transport/packet]
>  * /test_camera/camera/image_rect/theora [theora_image_transport/packet]
>  * /test_camera/camera/image_color [sensor_msgs/Image]
>  * /test_camera/camera/image_color/theora [theora_image_transport/packet]
>  * /test_camera/camera/image_rect_color/compressed [sensor_msgs/CompressedImage]
>  * /test_camera/camera/image_rect_color [sensor_msgs/Image]
>
> Subscriptions:
>  * /time [unknown type]
>  * /clock [unknown type]
>
> Services:
>  * /test_camera/camera/image_proc_1269693701464224000/get_loggers
>  * /test_camera/camera/image_proc_1269693701464224000/set_logger_level
>
> contacting node http://vision-4:40010/ ...
> Pid: 23544
> Connections:
>  * topic: /rosout
>    * to: /rosout
>    * direction: outbound
>    * transport: TCPROS
>
> joq at vision-4:~$ rosnode info /image_view_1269390714813267000
> --------------------------------------------------------------------------------
> Node [/image_view_1269390714813267000]
>
> Publications:
>  * /rosout [roslib/Log]
>
> Subscriptions:
>  * /time [unknown type]
>  * /clock [unknown type]
>  * /test_camera/camera/image_raw [sensor_msgs/Image]
>
> Services:
>  * /image_view_1269390714813267000/get_loggers
>  * /image_view_1269390714813267000/set_logger_level
>
> contacting node http://vision-4:47223/ ...
> Pid: 22116
> Connections:
>  * topic: /rosout
>    * to: /rosout
>    * direction: outbound
>    * transport: TCPROS
>  * topic: /test_camera/camera/image_raw
>    * to: http://vision-4:41029/
>    * direction: inbound
>    * transport: TCPROS
>
> (Note the missing subscription to /test_camera/camera/image_raw
> [sensor_msgs/Image] for the image_proc node.)
>
> I can't tell whether this may be what is happening to you as well. I
> don't know why the topic is not subscribed, but that explains why no
> data are published farther down the pipeline.
>
> I used the ROS_NAMESPACE=/test_camera/camera trick for starting
> image_proc. Maybe I am doing something wrong, but that is not clear
> from the http://ros.org/wiki/image_proc docs. Is there any more
> documentation on that node? Does it really have no parameters?
>
> I am running all this with the boxturtle release on Ubuntu 9.10.
>
> Since I am new to image_proc, pointers or suggestions from everyone
> would be helpful.
> --
>  joq
> _______________________________________________
> ros-users mailing list
> ros-users at code.ros.org
> https://code.ros.org/mailman/listinfo/ros-users
>



More information about the ros-users mailing list