mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-09 20:12:38 +02:00
bug fix: caching.py w.r.t. ignore_args
This commit is contained in:
parent
11059fb615
commit
9d312ab8ff
1 changed files with 1 additions and 0 deletions
|
|
@ -66,6 +66,7 @@ class Cacher(object):
|
||||||
#first make sure the depth limit isn't exceeded
|
#first make sure the depth limit isn't exceeded
|
||||||
if len(self.cached_inputs) == self.limit:
|
if len(self.cached_inputs) == self.limit:
|
||||||
args_ = self.cached_inputs.pop(0)
|
args_ = self.cached_inputs.pop(0)
|
||||||
|
args_ = [a for i,a in enumerate(args_) if i not in self.ignore_args and i not in self.force_kwargs]
|
||||||
[a.remove_observer(self, self.on_cache_changed) for a in args_ if a is not None]
|
[a.remove_observer(self, self.on_cache_changed) for a in args_ if a is not None]
|
||||||
self.inputs_changed.pop(0)
|
self.inputs_changed.pop(0)
|
||||||
self.cached_outputs.pop(0)
|
self.cached_outputs.pop(0)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue