Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Too many nodes with same name #9146

Open
3 tasks done
LuZhishan opened this issue Oct 24, 2024 · 4 comments
Open
3 tasks done

Too many nodes with same name #9146

LuZhishan opened this issue Oct 24, 2024 · 4 comments
Assignees
Labels
component:perception Advanced sensor data processing and environment understanding. (auto-assigned) type:improvement Proposed enhancement

Comments

@LuZhishan
Copy link

LuZhishan commented Oct 24, 2024

Checklist

  • I've read the contribution guidelines.
  • I've searched other issues and no duplicate issues were found.
  • I'm convinced that this is not my fault but a bug.

Description

When I launch many yolox node with multiple_yolox.launch.xml here, there will be many node with same name

Expected behavior

There should be many node with different names

Actual behavior

image

Steps to reproduce

  1. change the image_number larger than 1
  2. launch multiple_yolox.launch.xml

Versions

  • OS: ubuntu22.04
  • ROS2: hubmle
  • AutoWare: latest

Possible causes

No response

Additional context

There are two ways to solve this problem
The first one, change node name of tensorrt_yolox to $(anon tensorrt_yolox), and image_transport_decompressor_node to $(anon image_transport_decompressor_node)
The second one, add a param passed form uper launch named tensorrt_yolox_1 for example.

@cyn-liu cyn-liu self-assigned this Oct 25, 2024
@cyn-liu
Copy link
Contributor

cyn-liu commented Oct 25, 2024

@LuZhishan Thanks for your suggestion.
When I used the first method to solve this problem(draft PR), I found that the node names were still the same. I think this is abnormal. Does anyone know the reason? @mitsudome-r @xmfcx @dan-dnn @ktro2828 @manato

#ros2 node list
WARNING: Be aware that are nodes in the graph that share an exact name, this can have unintended side effects.
/image_transport_decompressor_node_cynthia_liu_25507_8885756925087757029
/image_transport_decompressor_node_cynthia_liu_25507_8885756925087757029
/tensorrt_yolox_cynthia_liu_25507_5677783873391810063
/tensorrt_yolox_cynthia_liu_25507_5677783873391810063

@badai-nguyen
Copy link
Contributor

@LuZhishan Thanks for your suggestion. When I used the first method to solve this problem(draft PR), I found that the node names were still the same. I think this is abnormal. Does anyone know the reason? @mitsudome-r @xmfcx @dan-dnn @ktro2828 @manato

#ros2 node list
WARNING: Be aware that are nodes in the graph that share an exact name, this can have unintended side effects.
/image_transport_decompressor_node_cynthia_liu_25507_8885756925087757029
/image_transport_decompressor_node_cynthia_liu_25507_8885756925087757029
/tensorrt_yolox_cynthia_liu_25507_5677783873391810063
/tensorrt_yolox_cynthia_liu_25507_5677783873391810063

@cyn-liu
I guess the reason is the multiple_yolox.launch.xml launch multi time yolox.launch.xml with name="$(anon tensorrt_yolox)" but in a very short time so that ROS2 is fail to create the distinct identifiers for each instance?
I think a better solution is adding a parameter for node name in yolox.lauch.xml and explicitly assign them in multi_yolox.launch.xml.

@badai-nguyen badai-nguyen added the component:perception Advanced sensor data processing and environment understanding. (auto-assigned) label Nov 8, 2024
@amadeuszsz
Copy link
Contributor

@badai-nguyen

I think a better solution is adding a parameter for node name in yolox.lauch.xml and explicitly assign them in multi_yolox.launch.xml.

FYI recently I was implementing something similar and I just followed same way as it is in ROS 2 geometry2 packages. It doesn't look nice but it works. I assume this approach might be good for packages with multiple instances.

@amadeuszsz amadeuszsz moved this from To triage to Backlog in Sensing & Perception Working Group Nov 8, 2024
@cyn-liu
Copy link
Contributor

cyn-liu commented Nov 22, 2024

@badai-nguyen

I think a better solution is adding a parameter for node name in yolox.lauch.xml and explicitly assign them in multi_yolox.launch.xml.

FYI recently I was implementing something similar and I just followed same way as it is in ROS 2 geometry2 packages. It doesn't look nice but it works. I assume this approach might be good for packages with multiple instances.

Perhaps method ROS 2 geometry2 packages is effective, but it is not the best choice in this node. In node tensorrt_yolox, object node_options is const type, and cannot call non const member function arguments().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:perception Advanced sensor data processing and environment understanding. (auto-assigned) type:improvement Proposed enhancement
Projects
Status: No status
Development

No branches or pull requests

5 participants