You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some functions are 'expensive' (they require quite a bit of compute time), and if the structure hasn't been modified, then these types of functions can be cached and the cache can be cleared if the cached property becomes invalid
Changing a property to be invalid only requires you to set `self.__cache__{method_name} = None` to clear the cached variable.
"""
defcached_property(expensive_function):
"""
A decorator function like @property that will cache return a cached quantity if it is available