From b58f52e40e5e8dbf3557124f31362bbfaeddca00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Sch=C3=B6nberger?= Date: Wed, 1 May 2013 11:15:09 +0200 Subject: [PATCH] Fix bug in predict_x of line model --- skimage/measure/fit.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/skimage/measure/fit.py b/skimage/measure/fit.py index cd9a7795..3b2d7d32 100644 --- a/skimage/measure/fit.py +++ b/skimage/measure/fit.py @@ -132,7 +132,7 @@ class LineModel(BaseModel): if params is None: params = self._params dist, theta = params - return (dist - y * math.cos(theta)) / math.cos(theta) + return (dist - y * math.sin(theta)) / math.cos(theta) def predict_y(self, x, params=None): '''Predict y-coordinates using the estimated model.