independent km caches for distinct cases; clear the Aesara cache if it's large #1127
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.
For Parca for operons #1123 : Put a checksum into the
KmcountsCached
cache filename so different cases get independent cache files, e.g. for mono/polycistronic operons or switching git branches. This succeeded with Parca options in a parameter optimization run. It's limited by needing to compute the checksum before readingKmcountsCached
but it's still backed up by the content check.It could be made more picky by checksumming more inputs or less picky by rounding
Kmcounts.astype(np.float16)
.This renames the cache file from
fixtures/endo_km/km3.cPickle
to (e.g.)cache/parca-km-1918837868.cPickle
.The cache files will accumulate until
make clean
.Q. Does anyone prefer the
fixtures/endo_km/
directory name?Fix Can Aesara cache be cleared automatically? #1120 :
make clean
will clear the current Aesara cache if it's larger than a threshold -- 30MB seems fair since the cache is 11MB locally and 350 MB in~tahorst
on Sherlock.Aesara's cache management is not straightforward, partly to handle multiple processes and NFS.