-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MAINT: use
functools
for memoization
- replace `@cached_var` with `@functools.lru_cache` and `@cached_const` with `@functools.cached_property` - refactor calls of any `cached_property`, now not callable anymore, substitute with `self.set_link_attribute(property)` where necessary - remove `cache_helper` and `cache` attribute in `core.network` - adapt `clear_cache()` methods accordingly, introduce `clear_cache_startswith()` - remove `Network.clear_link_attribute()` - adapt `Network.{del|set}_link_attribute()` accordingly, drop clearing cache of `path_lengths()` in `set_link_attribute()` - related issue: #148 - locally disable pylint false positive `not-callable` on `multiprocess.Pool()`
- Loading branch information
Showing
11 changed files
with
178 additions
and
231 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.