Mercurial Hosting > traffic-intelligence
diff python/moving.py @ 14:e7bbe8465591
homography and other utils
author | Nicolas Saunier <nico@confins.net> |
---|---|
date | Sat, 14 Nov 2009 19:02:46 -0500 |
parents | 30559b2cf7a9 |
children | 9d6831cfe675 |
line wrap: on
line diff
--- a/python/moving.py Fri Nov 13 19:29:01 2009 -0500 +++ b/python/moving.py Sat Nov 14 19:02:46 2009 -0500 @@ -101,6 +101,15 @@ from matplotlib.pylab import plot plot(self.positions[0], self.positions[1]) + def xBounds(self): + # look for function that does min and max in one pass + return [min(self.positions[0]), max(self.positions[0])] + + def yBounds(self): + # look for function that does min and max in one pass + return [min(self.positions[1]), max(self.positions[1])] + + class MovingObject(STObject): '''Class for moving objects i.e. with a trajectory and a geometry (volume)