Improved look-up table query scaling with variable count#2214
Merged
EvertBunschoten merged 9 commits intodevelopfrom Feb 26, 2024
Merged
Improved look-up table query scaling with variable count#2214EvertBunschoten merged 9 commits intodevelopfrom
EvertBunschoten merged 9 commits intodevelopfrom
Conversation
…ng comparisons, improving efficiency
Member
|
You may want to remove the string based interface since it's known to be inneficient. |
Member
Author
When replacing the string-based with index-based look-up methods, the performance improves substantially. The figure below shows the average measured evaluation time (measured with chrono library) vs the number of output variables. It's clear that using index-based look-up methods results in reduced query time, as well as improved scaling. |
bigfooted
approved these changes
Feb 25, 2024
Contributor
bigfooted
left a comment
There was a problem hiding this comment.
Thanks Evert, it looks good to me, Also nice improvement in speed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Proposed Changes
The
CLookUpTableclass allows for the fast interpolation of unstructured 2D data.It was found that the query time of this class scaled significantly with the number of output variables, indicating inefficiencies in the query process.
These inefficiencies came from string comparison routines in the
GetIndexOfVarfunction of theCLookUpTableclass. By implementing overloaded instances of the look-up functions which retrieve data from data indices directly, the query time efficiency scaling was significantly improved.Also reduced duplicate code within the
CLookUpTableclass.PR Checklist
Put an X by all that apply. You can fill this out after submitting the PR. If you have any questions, don't hesitate to ask! We want to help. These are a guide for you to know what the reviewers will be looking for in your contribution.
pre-commit run --allto format old commits.