Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Loading nodelets and nodes in the same launch file causes LibraryUnloadException

I have made a launch file that loads three nodelets (all are properly compiled and loaded), but when also loading a regular node, killing of the roslaunch process with Ctrl-C terminates the program, but also throws a LibraryUnloadException.

terminate called after throwing an instance of 'class_loader::LibraryUnloadException'
 what():  Attempt to unload library that class_loader is unaware of.
shutting down processing monitor...
... shutting down processing monitor complete
done

When the last <node> tag is removed, no such error occurs.

<launch>

<!-- hyperspec nodelet args-->
<arg name="use_raw_transport" default="false" />
<arg name="start_pylon_driver" default="false" />
<arg name="cb_corners_panorama" default="true" />

<arg name="exposure" default="50000.0" />
<arg name="frame_rate" default="20.0" />
<!-- end hyperspec nodelet args -->

<!-- nodelet manager -->
<arg name="manager_name" default="calibration_nodelet_manager"/>

<!-- Pylon args -->
<arg name="node_name" default="pylon_camera_node" />
<arg name="config_file" default="$(find pylon_camera)/config/pluto_pylon.yaml" />
<!-- end Pylon args -->


<!-- Manager -->
<node pkg="nodelet" type="nodelet" name="$(arg manager_name)" args="manager" output="screen"/>

<!-- Nodelet nodes -->
<node pkg="nodelet" type="nodelet" name="PylonNodelet"
    args="load pylon_camera/PylonNodelet $(arg manager_name)" output="screen" respawn="false">
    <param name="camera_frame" value="$(arg node_name)" type="string" />
    <rosparam command="load" file="$(arg config_file)" />
    <param name="frame_rate" value="$(arg frame_rate)" type="double" />
</node>

<node pkg="nodelet"
    type="nodelet"
    name="CleanImageNodelet"
    args="load hyperspectral_calibration/CleanImageNodelet $(arg manager_name)"
    output="screen"
    respawn="false">
    <remap from="/pylon_camera_node/image_raw" to="/$(arg manager_name)/image_raw"/>
    <param if="$(arg use_raw_transport)"
        name="image_transport"
        type="string"
        value="raw" />
    <param unless="$(arg use_raw_transport)"
        name="image_transport"
        type="string"
        value="compressed" />

</node>

<node pkg="nodelet"
    type="nodelet"
    name="PanoramaGrabberNodelet"
    args="load hyperspectral_calibration/PanoramaGrabberNodelet $(arg manager_name)"
    output="screen"
    respawn="false">
</node>

<node pkg="rosservice"
    name="srv_exposure"
    type="rosservice"
    args="call --wait /pylon_camera_node/set_exposure $(arg exposure)"
    />

<!-- REMOVE THIS -- Start chessboard detector -->
<node if="$(arg cb_corners_panorama)"
    name="find_corners_panorama"
    pkg="hyperspectral_calibration"
    type="find_corners_panorama"
    respawn="false"
    output="screen"
    />
</launch>

Can someone explain this behaviour?