From 26e6223ff4e02cca8135f6327c639ff090df9411 Mon Sep 17 00:00:00 2001 From: Dev Singh Date: Wed, 23 Sep 2020 14:31:29 +0000 Subject: [PATCH] fix: correct indentation Signed-off-by: Dev Singh --- analysis-master/tra_analysis/fits.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/analysis-master/tra_analysis/fits.py b/analysis-master/tra_analysis/fits.py index e6db917f..d875685b 100644 --- a/analysis-master/tra_analysis/fits.py +++ b/analysis-master/tra_analysis/fits.py @@ -27,12 +27,12 @@ class CircleFit: # For more information on the LSC method, see: # http://www.dtcenter.org/sites/default/files/community-code/met/docs/write-ups/circle_fit.pdf def __init__(self, x, y, xy=None): - if type(x) == list: - x = np.array(x) - if type(y) == list: - y = np.array(y) - if type(xy) == list: - xy = np.array(xy) + if type(x) == list: + x = np.array(x) + if type(y) == list: + y = np.array(y) + if type(xy) == list: + xy = np.array(xy) if data != None: self.coords = data self.ournp = np #todo: implement cupy correctly @@ -43,9 +43,9 @@ class CircleFit: """Returns distance between center and point""" return self.ournp.sqrt((x-xc)**2 + (y-yc)**2) def f(c, x, y): - """Returns distance between point and circle at c""" - Ri = calc_R(x, y, *c) - return Ri - Ri.mean() + """Returns distance between point and circle at c""" + Ri = calc_R(x, y, *c) + return Ri - Ri.mean() def LSC(self): """Fits given data to a circle and returns the center, radius, and variance""" x = coords[:, 0]