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

[backend-comparison] Burnbench CLI #1260

Merged
merged 15 commits into from Feb 7, 2024

Conversation

syl20bnr
Copy link
Member

@syl20bnr syl20bnr commented Feb 5, 2024

Checklist

  • Confirmed that run-checks all script has been executed.
  • Made sure the book is up to date with changes in this PR.

Related Issues/PRs

Issue #1072

Changes

Add a new binary to backend-comparison crate called burnbench.

There are two mods for this CLI: term and tui. The UI is a work in progress and must be enabled explicitly with the tui feature.

See the README for details about the CLI user experience. I tried to made it auto-discoverable and auto-correct as much as possible. For instance typos show the list of supported benchmarks or backends with a proposal to fix it:

image

I chose to repeat the arguments --backend and --bench instead of using comma separated list because the code is simpler and it better leverage clap and strum.

I chose l-b shorthand for a bench and -B for backend because the tool is about benchmarks so I believe that the natural lower case is for a bench.

I'll open a different PR for the upload.

Testing

Here is two commands to quickly test:

cargo run --bin burnbench -- list
cargo run --bin burnbench -- run --bench unary --bench binary --backend wgpu-fusion --backend wgpu

Copy link

codecov bot commented Feb 5, 2024

Codecov Report

Attention: 127 lines in your changes are missing coverage. Please review.

Comparison is base (9df2071) 84.41% compared to head (8cac2d6) 84.26%.
Report is 16 commits behind head on main.

Files Patch % Lines
backend-comparison/src/burnbenchapp/base.rs 0.00% 58 Missing ⚠️
burn-dataset/src/vision/image_folder.rs 79.91% 49 Missing ⚠️
backend-comparison/src/burnbenchapp/term/base.rs 0.00% 17 Missing ⚠️
backend-comparison/src/bin/burnbench.rs 0.00% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1260      +/-   ##
==========================================
- Coverage   84.41%   84.26%   -0.15%     
==========================================
  Files         549      553       +4     
  Lines       61952    62275     +323     
==========================================
+ Hits        52295    52478     +183     
- Misses       9657     9797     +140     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@nathanielsimard nathanielsimard left a comment

Choose a reason for hiding this comment

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

I don't have much comments, seems good in general!

backend-comparison/Cargo.toml Outdated Show resolved Hide resolved
backend-comparison/README.md Outdated Show resolved Hide resolved
@nathanielsimard nathanielsimard merged commit 5bef9d8 into tracel-ai:main Feb 7, 2024
13 of 14 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.

None yet

2 participants