Browse code

2D: rename _interpolate_combined -> _interpolator_combined

Bas Nijholt authored on 09/10/2019 09:27:42
Showing 1 changed files
... ...
@@ -476,7 +476,7 @@ class Learner2D(BaseLearner):
476 476
             points, values = self._data_in_bounds()
477 477
             return interpolate.LinearNDInterpolator(points, values)
478 478
 
479
-    def _interpolate_combined(self):
479
+    def _interpolator_combined(self):
480 480
         """A `scipy.interpolate.LinearNDInterpolator` instance
481 481
         containing the learner's data *and* interpolated data of
482 482
         the `pending_points`."""
... ...
@@ -513,7 +513,7 @@ class Learner2D(BaseLearner):
513 513
             raise ValueError("too few points...")
514 514
 
515 515
         # Interpolate
516
-        ip = self._interpolate_combined()
516
+        ip = self._interpolator_combined()
517 517
 
518 518
         losses = self.loss_per_triangle(ip)
519 519
 
... ...
@@ -581,7 +581,7 @@ class Learner2D(BaseLearner):
581 581
     def loss(self, real=True):
582 582
         if not self.bounds_are_done:
583 583
             return np.inf
584
-        ip = self.interpolator(scaled=True) if real else self._interpolate_combined()
584
+        ip = self.interpolator(scaled=True) if real else self._interpolator_combined()
585 585
         losses = self.loss_per_triangle(ip)
586 586
         return losses.max()
587 587