Skip to content

Add groot2 tutorial#645

Merged
SteveMacenski merged 8 commits intoros-navigation:masterfrom
mini-1235:master
Apr 4, 2025
Merged

Add groot2 tutorial#645
SteveMacenski merged 8 commits intoros-navigation:masterfrom
mini-1235:master

Conversation

@mini-1235
Copy link
Copy Markdown
Collaborator

Mostly copied from the Groot(1) tutorial, but I have deleted some contents that are only showing Groot(1), I have also added some contents as well as the screenshots for Groot2

@mini-1235 mini-1235 marked this pull request as draft February 17, 2025 12:22
@mini-1235
Copy link
Copy Markdown
Collaborator Author

So if you build my docs, you will see that the Groot2 figures have the wrong numbering.
It should have started from figure1, but as there are 6 pics in the Groot(1) tutorial it is starting from 7
iShot_2025-02-17_20 25 59
I cannot find any elegant solution, can you help on this @SteveMacenski

Comment thread tutorials/index.rst Outdated
Comment thread configuration/packages/configuring-bt-navigator.rst Outdated
Comment thread configuration/packages/configuring-bt-xml.rst Outdated
Comment thread tutorials/docs/using_groot2.rst Outdated
Comment thread tutorials/docs/using_groot2.rst Outdated
| | :width: 180% |
| | |
| UI to describing new Nodes | The New Custom Node |
+--------------------------------------------------------------+--------------------------------------------------------------+ No newline at end of file
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add at the end the same as in Groot 1 as:

Before starting to create a new BT based on the new custom nodes, it is recommend to export the newly created nodes to save in case of Groot crashing. This can be performed with the icon highlighted in green from [Figure 6](https://output.circle-artifacts.com/output/job/e1bbcc55-9a1f-4246-8359-f48dd32bdd87/artifacts/0/html/tutorials/docs/using_groot.html#groot-export-new-node). The resulting XML output from the node created in [Figure 5](https://output.circle-artifacts.com/output/job/e1bbcc55-9a1f-4246-8359-f48dd32bdd87/artifacts/0/html/tutorials/docs/using_groot.html#groot-interactive-node-creation) can be seen below. You can see more examples in [Nav2’s BT Node Palette XML](https://github.com/ros-navigation/navigation2/blob/main/nav2_behavior_tree/nav2_tree_nodes.xml).

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn’t find the export button in Groot2—could you help me check if it actually exists?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I honestly don't know; I haven't used Groot2 :-) @facontidavide can you help answer this question for adding a Groot2 tutorial?

@SteveMacenski
Copy link
Copy Markdown
Member

SteveMacenski commented Mar 10, 2025

@mini-1235 I'm not sure either, but I found that you used figure instead of image, so maybe try that instead so that it doesn't reference the specific numbers? This is what we do in move other tutorials:


.. image:: images/my_img.png
    :width: some-number-px

The tutorial would need to be adjusted to not rely as much on referencing specific image numbers, however.

Edit:

ChatGPT recommends uncommenting and adjusting

#numfig_secnum_depth = (2)
to try 1 or 2 (without the ()). See if that works! It will reset the numbering of figures on the section and subsection, respectively. I'm not sure which is right, so worth just quickly testing both. Find where else .. figure is used and check that those are OK too, but I suspect the the groot 1 tutorial is the only place that they are used

@mini-1235
Copy link
Copy Markdown
Collaborator Author

Sorry for the late response here, I was very busy last week.

Edit:

ChatGPT recommends uncommenting and adjusting

#numfig_secnum_depth = (2)

to try 1 or 2 (without the ()). See if that works! It will reset the numbering of figures on the section and subsection, respectively.

I have tried this actually, it doesn't work, so maybe I should use image instead of figure as you suggested?

@SteveMacenski
Copy link
Copy Markdown
Member

Agreed!

Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
@mini-1235 mini-1235 marked this pull request as ready for review March 21, 2025 17:09
Comment thread tutorials/docs/adding_a_nav2_task_server.rst Outdated
Comment thread tutorials/docs/using_groot.rst Outdated
Comment thread tutorials/docs/using_groot.rst
Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
Comment thread tutorials/docs/using_groot.rst Outdated
Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
@SteveMacenski
Copy link
Copy Markdown
Member

I couldn’t find the export button in Groot2—could you help me check if it actually exists?

I think this is the last thing before this can be merged. @facontidavide how do you export BTs in Groot 2?

@mini-1235
Copy link
Copy Markdown
Collaborator Author

mini-1235 commented Apr 3, 2025

I spent more time to try Groot2 today, and it seems that exporting a single node described in the Groot (1) tutorial is not directly supported.
However, it is possible to export if we added it to a tree:

  1. Drag the node into the tree
  2. Export the whole project / Save the current project
    Assuming our current tree is navigate_to_pose_w_replanning_and_recovery.xml then we can find the node in <TreeNodesModel></TreeNodesModel>

Do you want me to add this to the Groot2 tutorial? 😄 @SteveMacenski

@SteveMacenski
Copy link
Copy Markdown
Member

I think you could show how to export a tree in general and I'd be happy with that to close this up and merge it (doesn't need to be specific about a custom node, just show how to export a tree in general after they're done). I think that meets the intent that this served in the original document anyway!

Signed-off-by: Maurice-1235 <mauricepurnawan@gmail.com>
@SteveMacenski SteveMacenski merged commit 2703efe into ros-navigation:master Apr 4, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants