mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-09 12:02:38 +02:00
[caching] id fix
This commit is contained in:
parent
64fb6ddc4c
commit
b050e1fb64
1 changed files with 2 additions and 1 deletions
|
|
@ -44,7 +44,8 @@ class Cacher(object):
|
|||
# we have reached the limit, so lets release one element
|
||||
cache_id = self.order.popleft()
|
||||
combined_args_kw = self.cached_inputs[cache_id]
|
||||
for ind_id in combined_args_kw:
|
||||
for ind in combined_args_kw:
|
||||
ind_id = id(ind)
|
||||
ref, cache_ids = self.cached_input_ids[ind_id]
|
||||
if len(cache_ids) == 1 and ref() is not None:
|
||||
ref().remove_observer(self, self.on_cache_changed)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue