Mercurial > hg > nsaunier > traffic-intelligence
comparison python/moving.py @ 411:31604ef1cad4
added hog functions and the display of road user types if known
| author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
|---|---|
| date | Wed, 21 Aug 2013 00:00:23 -0400 |
| parents | 0ce2210790b1 |
| children | cd342a774806 |
comparison
equal
deleted
inserted
replaced
| 410:91954c76d12c | 411:31604ef1cad4 |
|---|---|
| 629 class MovingObject(STObject): | 629 class MovingObject(STObject): |
| 630 '''Class for moving objects: a spatio-temporal object | 630 '''Class for moving objects: a spatio-temporal object |
| 631 with a trajectory and a geometry (constant volume over time) and a usertype (e.g. road user) coded as a number (see | 631 with a trajectory and a geometry (constant volume over time) and a usertype (e.g. road user) coded as a number (see |
| 632 ''' | 632 ''' |
| 633 | 633 |
| 634 def __init__(self, num = None, timeInterval = None, positions = None, velocities = None, geometry = None, userType = None): | 634 def __init__(self, num = None, timeInterval = None, positions = None, velocities = None, geometry = None, userType = userType2Num['unknown']): |
| 635 super(MovingObject, self).__init__(num, timeInterval) | 635 super(MovingObject, self).__init__(num, timeInterval) |
| 636 self.positions = positions | 636 self.positions = positions |
| 637 self.velocities = velocities | 637 self.velocities = velocities |
| 638 self.geometry = geometry | 638 self.geometry = geometry |
| 639 self.userType = userType | 639 self.userType = userType |
