-
Notifications
You must be signed in to change notification settings - Fork 249
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
Performance benchmarking refactor #594
Conversation
e0e6118
to
c0bcbf1
Compare
1294602
to
5a8e6f2
Compare
@mjeronimo @emersonknapp @Karsten1987 this is ready for a review now |
7219b37
to
c6ef8ff
Compare
...e/rosbag2_performance_benchmarking/include/rosbag2_performance_benchmarking/config_utils.hpp
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pretty complicated - very big review, but since it's not direct product code, i'm inclined to merge it if it works as desired
We already used it to run numerous experiments (reports are incoming) and it works for us reliably. I agree it can be difficult to review since it is quite big. |
Gist: https://gist.githubusercontent.com/emersonknapp/7bc8c2396115fc7b1d52a2fc8f8c9ea0/raw/7d026faddaa306b579571fb44d4d3ae65f33f992/ros2.repos |
test failure: since the code of this PR is contained in an independent package that in no way affects rosbag2 recording, I assume that this is a flaky test. Edit: corrected spelling of the flag. |
I have added that, but the main problem is my mistake: I asked for package |
The flag needs to be --cmake-args -DBUILD_ROSBAG2_BENCHMARKS=1. My apologies for giving a wrong spelling and no value in an earlier comment (this is in the README, but I guess the late hour works against me) |
I fixed Windows build issue with uint (which is an usual compiler shortcut but not supported by all compilers). Perhaps all will be green this time :] |
- renamed since now it no longer benchmarks writer only - generalized byte_producer so that it uses a callback instead of queue, so it can be reused in publisher scheme Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
- can specify multiple groups of publishers (see attached example yaml) - reuses byte producer Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
Also included in yaml example. Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> added comment in storage_optimized.yaml
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
…ild) Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>
2f1066c
to
fe8b6b2
Compare
Where? If you mean the "Rpr" build - it isn't a good indicator of success, because it only builds against released versions of packages, rather than against the latest version of the code. In this case, rcpputils has a new const-specifier that is merged in master but not released in rolling yet - I would ignore that build and pay attention to "Test rosbag2 / build_and_test (pull_request) " and the ci.ros2.org builds in general, which both build from source |
Are there any plans to backport it to Foxy? |
@y-okumura-isp I will soon be able to update you on this, since it is a ongoing decision process that also needs feedback from the community. If I can support you in the meanwhile, please let me know - you can find my email in the commit log. The same applies to double buffering PR (#546) - I saw you were also interested in this one. |
* Refactoring of rosbag2 performance package: - renamed since now it no longer benchmarks writer only - generalized byte_producer so that it uses a callback instead of queue, so it can be reused in publisher scheme Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Benchmark publishers based on yaml configuration - can specify multiple groups of publishers (see attached example yaml) - reuses byte producer Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Applying configured QoS settings for publishers. Also included in yaml example. Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * linters Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Towards common configuration - separating out common structures - utility class for common parameter parsing Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Barebone launchfile for benchmarks. Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * writer benchmark adapted to yaml file and publisher groups Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * refactored result writing and bag parameters Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * linters Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Launchfile for benchmarks Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Change storage config file from non optimized to resilient Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Max bag size for benchmark launchfile. Launchfile refactor. Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Copy yaml configs after benchmark is finished. Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Benchmark results csv file extended Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * added disclaimer about random data and compression Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Report gen tool for benchmarks Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Benchmarks out dir name changed Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * results writer node Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * documentation Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Transport and transportless in launchfile Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Benchmark launchfile refactor Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Wait for rosbag listening in benchmark launchfile Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Uncrustify and some comments for benchmarking tools Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Added new producers config for benchmarks Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Missing parameters in transport benchmark Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> added comment in storage_optimized.yaml * Missing rosbag record parameters in transport benchmark Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Wait for subscriptions parameter in producers config Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * moved utils code from header to source Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * changed compiler shortcut uint to unsigned int (should fix Windows build) Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> Co-authored-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai>
* Refactoring of rosbag2 performance package: - renamed since now it no longer benchmarks writer only - generalized byte_producer so that it uses a callback instead of queue, so it can be reused in publisher scheme Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Benchmark publishers based on yaml configuration - can specify multiple groups of publishers (see attached example yaml) - reuses byte producer Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Applying configured QoS settings for publishers. Also included in yaml example. Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * linters Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Towards common configuration - separating out common structures - utility class for common parameter parsing Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Barebone launchfile for benchmarks. Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * writer benchmark adapted to yaml file and publisher groups Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * refactored result writing and bag parameters Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * linters Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Launchfile for benchmarks Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Change storage config file from non optimized to resilient Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Max bag size for benchmark launchfile. Launchfile refactor. Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Copy yaml configs after benchmark is finished. Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Benchmark results csv file extended Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * added disclaimer about random data and compression Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Report gen tool for benchmarks Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Benchmarks out dir name changed Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * results writer node Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * documentation Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * Transport and transportless in launchfile Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Benchmark launchfile refactor Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Wait for rosbag listening in benchmark launchfile Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Uncrustify and some comments for benchmarking tools Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Added new producers config for benchmarks Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Missing parameters in transport benchmark Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> added comment in storage_optimized.yaml * Missing rosbag record parameters in transport benchmark Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * Wait for subscriptions parameter in producers config Signed-off-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> * moved utils code from header to source Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> * changed compiler shortcut uint to unsigned int (should fix Windows build) Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai> Co-authored-by: Piotr Jaroszek <piotr.jaroszek@robotec.ai> Signed-off-by: Emerson Knapp <eknapp@amazon.com>
Improvements to current performance benchmarking package: