comparison 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
comparison
equal deleted inserted replaced
13:30559b2cf7a9 14:e7bbe8465591
99 99
100 def draw(self): 100 def draw(self):
101 from matplotlib.pylab import plot 101 from matplotlib.pylab import plot
102 plot(self.positions[0], self.positions[1]) 102 plot(self.positions[0], self.positions[1])
103 103
104 def xBounds(self):
105 # look for function that does min and max in one pass
106 return [min(self.positions[0]), max(self.positions[0])]
107
108 def yBounds(self):
109 # look for function that does min and max in one pass
110 return [min(self.positions[1]), max(self.positions[1])]
111
112
104 class MovingObject(STObject): 113 class MovingObject(STObject):
105 '''Class for moving objects 114 '''Class for moving objects
106 i.e. with a trajectory and a geometry (volume) 115 i.e. with a trajectory and a geometry (volume)
107 and a type (e.g. road user) 116 and a type (e.g. road user)
108 ''' 117 '''