Skip to content

Commit 8bfd429

Browse files
committed
make loss equal to (ntotal - npoints) / ntotal
1 parent ab3780c commit 8bfd429

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

adaptive/learner/sequence_learner.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@ def loss(self, real=True):
5959
return 0
6060
else:
6161
npoints = self.npoints + (0 if real else len(self.pending_points))
62-
return inf / npoints
62+
ntotal = len(self.sequence)
63+
return (ntotal - npoints) / ntotal
6364

6465
def remove_unfinished(self):
6566
for p in self.pending_points:

0 commit comments

Comments
 (0)