Closed Conzel closed 3 years ago
Only writing "@lru_cache" over a function f causes python to call the decorator with "@lru_cache(f)", which results in the decorator assuming f to be the max_size argument.
More can be read here: https://stackoverflow.com/questions/47218313/use-functools-lru-cache-without-specifying-maxsize-parameter
This fixes a problem with the HiLLoC Notebook, where the 5th cell does not run due to the error described above: https://colab.research.google.com/drive/11967hjFQczjW21cLLTFhOnTurx3mSBVD#scrollTo=YxbS0ywnKKIg
Tests and example run as before :)
Thanks! Sorry i took so long to get to this.
Only writing "@lru_cache" over a function f causes python to call the decorator with "@lru_cache(f)", which results in the decorator assuming f to be the max_size argument.
More can be read here: https://stackoverflow.com/questions/47218313/use-functools-lru-cache-without-specifying-maxsize-parameter
This fixes a problem with the HiLLoC Notebook, where the 5th cell does not run due to the error described above: https://colab.research.google.com/drive/11967hjFQczjW21cLLTFhOnTurx3mSBVD#scrollTo=YxbS0ywnKKIg
Tests and example run as before :)