From 00dd0718fa2ff392cd9bd19ff72b31cb3e5ab137 Mon Sep 17 00:00:00 2001 From: Jan Petykiewicz Date: Wed, 27 Nov 2019 19:32:25 -0800 Subject: [PATCH] fix center calculation --- gridlock/grid.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gridlock/grid.py b/gridlock/grid.py index fe78aa3..ff39122 100644 --- a/gridlock/grid.py +++ b/gridlock/grid.py @@ -108,7 +108,7 @@ class Grid(object): """ # center is just average of first and last xyz, which is just the average of the # first two and last two exyz - centers = [(self.exyz[a][:2] + self.exyz[a][-2:]) / 4.0 for a in range(3)] + centers = [(self.exyz[a][:2] + self.exyz[a][-2:]).sum() / 4.0 for a in range(3)] return numpy.array(centers, dtype=float) @property