broadinstitute / adapt

A package for designing activity-informed nucleic acid diagnostics for viruses.
MIT License
28 stars 1 forks source link

Reduce required memory and runtime of guide memoization #13

Closed haydenm closed 5 years ago

haydenm commented 5 years ago

This PR makes several changes to reduce the memory required by guide_search.GuideSearcher's memoization of designed guides (i.e., in _memoized_guides), as well as the runtime associated with it:

Two of these changes will decrease runtime (c90c96c and 2d4e340), but the rest are likely to slightly increase it.

The changes decrease memory as expected and, on large numbers of diverse input, also decrease runtime in net. The changes are considerable. Below are benchmark results for design on 48,108 sequences of IAV segment 6 (42,399 after curation/clustering):