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

Run benchmarks nloop times #105

Merged
merged 1 commit into from
Apr 14, 2021
Merged

Run benchmarks nloop times #105

merged 1 commit into from
Apr 14, 2021

Conversation

RReverser
Copy link
Collaborator

Looks like at least some benches already used nloop variable in time calculations, but never looped. Each benchmark executing just once resulted in fairly unreliable numbers across runs.

This change makes each bench run 50 times, and averages the timing across them, making numbers more reproducible.

Looks like at least some benches already used nloop variable in time calculations, but never looped. Each benchmark executing just once resulted in fairly unreliable numbers across runs.

This change makes each bench run 50 times, and averages the timing across them, making numbers more reproducible.
@kbarbary
Copy link
Owner

Is the runtime still pretty reasonable with nloop=50? I think maybe the reason I set nloop=1 was that, at least for the aperture functions, there's already an inner loop over the 1000 apertures.

@RReverser
Copy link
Collaborator Author

Is the runtime still pretty reasonable with nloop=50?

Yeah it's like 3-5 seconds on my laptop.

at least for the aperture functions, there's already an inner loop over the 1000 apertures

Ah okay, I was mostly looking at variations in sep.Background runs which wasn't covered by this. If you want, I can revert the changes to run the loop 50 times only for this function, but, as I said, it's still pretty fast anyway.

@kbarbary kbarbary merged commit 6e8fbbd into kbarbary:master Apr 14, 2021
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