hubverse-org / hubValidations

Testing framework for hubverse hub validations
https://hubverse-org.github.io/hubValidations/
Other
1 stars 3 forks source link

Memoise `expand_model_out_vals_grid` #85

Open annakrystalli opened 1 month ago

annakrystalli commented 1 month ago

As config files become more complex, this function becomes more computationally expensive.

Because this function effectively evaluates to the same output everytime for a given hub (unless of course the config changes), it's a good candidate for memoisation, especially for use in a function to validate many files in a hub (#83 )

If implemented, a note in the docs should also be included to alert users that if they make changes to the config in between calls they should refresh their session to clear the cache.