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

Speed up correct_k #8

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Carter12s
Copy link

Profiling the chemdose_ph_chain examples from the vignettes, correct_k was noticed to be slow:
image

Applying optimizations contained within:

image

correct_k goes from 1980ms to 90ms (-95.4% faster)

Overall example goes from 7.74s to 5.67s (-27% faster).

These changes and gains are independent of: #7

@Carter12s
Copy link
Author

This this MR with #7 yields:

image

7.7s -> 2.2s = -68% faster

@sierrajohnson sierrajohnson added the enhancement New feature or request label Nov 11, 2024
@sierrajohnson sierrajohnson self-requested a review November 11, 2024 20:01
Copy link
Collaborator

@sierrajohnson sierrajohnson left a comment

Choose a reason for hiding this comment

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

The change makes sense, but all the k values in correct_k should be written as 10^x (industry standard) - you can see these in the raw data file. Also, let's keep discons and reference it in the comments of correct_k so that package users can still see where the data come from.

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

Successfully merging this pull request may close these issues.

2 participants