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

feat(contributing): add task scheduling #282

Conversation

shulanbushangshu
Copy link
Contributor

@shulanbushangshu shulanbushangshu commented Dec 15, 2022

Description

This pr adds ''task-scheduling" in contributing

Related to: #293

Pre-review checklist for the PR author

The PR author must check the checkboxes below when creating the PR.

In-review checklist for the PR reviewers

The Reviewers must check the checkboxes below before approval.

Post-review checklist for the PR author

The PR author must check the checkboxes below before merging.

  • There are no open discussions or they are tracked via tickets.

After all checkboxes are checked, anyone who has write access can merge the PR.

@takam5f2 takam5f2 added the tag:deploy-docs Mark for deploy-docs action generation. (used-by-ci) label Dec 15, 2022
Signed-off-by: jack.song <jack.song@autocore.ai>
Signed-off-by: jack.song <jack.song@autocore.ai>
Signed-off-by: jack.song <jack.song@autocore.ai>
Copy link
Contributor

@takam5f2 takam5f2 left a comment

Choose a reason for hiding this comment

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

@shulanbushangshu
Thank you for your contribution.

To my understanding, Autoware is not implemented without considering task scheduling so far. Autoware relies on task scheduling which is managed by ROS 2 and Linux. Task scheduling is one of the issue to be tackled in the future.

It is better, I think, that this section honestly tells that task scheduling is not designed and Autoware runs on a task scheduling by combination of ROS 2 and Linux kernel. "Introducing task optimized task scheduling mechanism and applying it to Autoware are one of our future work" is required statement here.


Under Construction
The software of autoware is the system of multiple nodes.In ROS2 the executor uses one or more threads of the underlying operating system to invoke the callbacks. The different type of callback has the different priority.
In autoware,there are two types about "publish-subscribe":
Copy link
Contributor

Choose a reason for hiding this comment

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

I think that there are two types of trigger for executing callback, but it is not "publish-subscribe", strictly speaking.


```bash
mkdir src
vcs import src < caret.repos --recursive
Copy link
Contributor

Choose a reason for hiding this comment

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

--recursive is not necessary.

Suggested change
vcs import src < caret.repos --recursive
vcs import src < caret.repos

4. Build the workspace.

```bash
source /opt/ros/galactic/setup.bash(or source /opt/ros/humble/setup.bash)
Copy link
Contributor

Choose a reason for hiding this comment

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

Installation of caret for galactic should not be mentioned here, I think.

Suggested change
source /opt/ros/galactic/setup.bash(or source /opt/ros/humble/setup.bash)
source /opt/ros/humble/setup.bash

@sykwer
Copy link
Member

sykwer commented Dec 22, 2022

@shulanbushangshu

Thank you for writing the first draft of the task scheduling document!

We TIER Ⅳ members are now working on scheduling issues on Linux platforms. Our opinion is that the task scheduling document should be about how to configure the settings of a kernel scheduler to run Autoware in a predictable way. Based on workload analysis and detailed analysis of the implementation of the Linux kernel, we plan to publish a specialized functionality for the task scheduling of Autoware on Linux and the documentation about it.

Additionally, we need to deal with double scheduling problems (ROS2 executer and kernel scheduler) and scheduler settings for specialized operating systems. We are also struggling with these problems. User-defined and centralized task scheduler will be developed specialized for Autoware.

As a result, we’d like to keep this document blank until the functionality as explained above become fixed.
Thanks!

Comment on lines +5 to +6
The software of autoware is the system of multiple nodes.In ROS2 the executor uses one or more threads of the underlying operating system to invoke the callbacks. The different type of callback has the different priority.
In autoware,there are two types about "publish-subscribe":
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
The software of autoware is the system of multiple nodes.In ROS2 the executor uses one or more threads of the underlying operating system to invoke the callbacks. The different type of callback has the different priority.
In autoware,there are two types about "publish-subscribe":
Autoware is a system made of multiple ROS2 nodes.
In ROS2 the executor uses one or more threads of the underlying operating system to invoke the callbacks.
Callbacks are units of work like subscription callbacks, timer callbacks, service calls, and received client responses.
The different types of callback has the different priority. Here are the priorities for:

Reference documentation: https://docs.ros2.org/latest/api/rclpy/api/execution_and_callbacks.html#module-rclpy.executors

Also made some small fixes like spaces after commas and periods.

@xmfcx xmfcx added type:documentation Creating or refining documentation. type:new-feature New functionalities or additions, feature requests. labels Dec 23, 2022
@xmfcx
Copy link
Contributor

xmfcx commented Dec 23, 2022

@sykwer

As a result, we’d like to keep this document blank until the functionality as explained above become fixed. Thanks!

I think it's ok to merge this proposal (after reviewing) and when you have a better proposal, it can be improved with that? Is that ok with you?

@xmfcx
Copy link
Contributor

xmfcx commented Dec 23, 2022

@shulanbushangshu

It's a great documentation addition overall, thanks for the work.

Before it's merged, could you also update the punctuation please? Mainly put a space after commas and periods.

@sykwer
Copy link
Member

sykwer commented Dec 25, 2022

I agree with this opinion.

#282 (review)

It is better, I think, that this section honestly tells that task scheduling is not designed and Autoware runs on a task scheduling by combination of ROS 2 and Linux kernel.

This opinion most accurately describes reality.

@xmfcx
Copy link
Contributor

xmfcx commented Dec 25, 2022

@sykwer

I agree with this opinion.

What do you agree with exactly? What do you think we should do in this PR?

@shulanbushangshu
Copy link
Contributor Author

shulanbushangshu commented Dec 27, 2022

@sykwer @xmfcx @takam5f2
Thank for your check. I will continue to pay attention to this section. As said,task scheduling is not designed in autoware and it just runs on a task scheduling by combination of ROS 2 and Linux kernel.
As in the future develop of autoware, autoware will develop user-defined and centralized task scheduler?
My understand about this section is that something about ROS2 executor in application of autoware by now.(Because task scheduling is not designed by now).
If it is necessary to explain the future ,I agree that keeping this document blank.

@xmfcx
Copy link
Contributor

xmfcx commented Jan 6, 2023

Created the issue to address this problem once the solution @sykwer and @takam5f2 suggested is implemented. Still, thank you @shulanbushangshu for working on this documentation!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tag:deploy-docs Mark for deploy-docs action generation. (used-by-ci) type:documentation Creating or refining documentation. type:new-feature New functionalities or additions, feature requests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants