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

Crossing boundry between units in a single graph #15

Open
jasonwilliams opened this issue Jan 21, 2020 · 5 comments
Open

Crossing boundry between units in a single graph #15

jasonwilliams opened this issue Jan 21, 2020 · 5 comments
Labels
enhancement New feature or request

Comments

@jasonwilliams
Copy link

jasonwilliams commented Jan 21, 2020

Hey @rhysd , great work on this.
Is anything supposed to happen if some data crosses the boundry between say nanoseconds and microseconds?

In my benchmark here that has happened in the bottom two:
https://jasonwilliams.github.io/boa/dev/bench/

It looks like its become a lot slower, but actually it sped up from 1 us to 900 ns.
Unfortunately once the chart is made with a unit im guessing its fixed.

think i answered my own question
https://github.com/rhysd/github-action-benchmark/blob/master/src/default_index_html.ts#L198

@jasonwilliams
Copy link
Author

jasonwilliams commented Jan 21, 2020

I have an idea, which could be to use math.js to convert what ever future values back to the right unit, math.eval(901.86 ns to us) => 0.90186 us.

This could be broken down into 2 tasks:

  1. get the most common unit for that series
  2. use math.js to convert current value + unit to that unit

@jasonwilliams
Copy link
Author

jasonwilliams commented Jan 23, 2020

This is a bit messy right now but ive got it working here:
https://github.com/jasonwilliams/github-action-benchmark/blob/local-add-criterion-support/src/default_index_html.ts

Example of it working here (on the bottom graph highlight the third node it should be in ns):
https://jasonwilliams.github.io/boa/dev/bench/

@rhysd
Copy link
Member

rhysd commented Jan 24, 2020

Thank you for the work. Let me take a look after Criterion.rs support has landed.

@ningziwen ningziwen added the enhancement New feature or request label May 9, 2023
@wwerkk
Copy link

wwerkk commented Apr 15, 2024

Any news on this?

Bench tools such as Catch2 can output value and range using different units, at the moment only the unit coming with the value is stored and displayed, which results in storage and display errors.

See Catch2 log:
Screenshot 2024-04-15 at 12 35 29
Corresponding entry in data.js file:
Screenshot 2024-04-15 at 12 35 39
This obviously displays as mean value of 9.24651 ms with deviation of ~556 ms.

@wwerkk
Copy link

wwerkk commented Apr 18, 2024

Normalising the units when filling the datasets, ie. to seconds, also does the trick, unless you care that much about being as accurate as possible.

I have an idea, which could be to use math.js to convert what ever future values back to the right unit, math.eval(901.86 ns to us) => 0.90186 us.

This could be broken down into 2 tasks:

1. get the most common unit for that series

2. use math.js to convert current value + unit to that unit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants