Mercurial > hg > nsaunier > traffic-intelligence
comparison python/tests/storage.txt @ 834:119c4efe6398
added option to load subsampled trajectories
| author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
|---|---|
| date | Thu, 30 Jun 2016 14:19:59 -0400 |
| parents | 180b6b0231c0 |
| children | 6db83beb5350 |
comparison
equal
deleted
inserted
replaced
| 833:8d1dd771aeb3 | 834:119c4efe6398 |
|---|---|
| 36 True | 36 True |
| 37 >>> o1.getPositions() == objects[0].getPositions() | 37 >>> o1.getPositions() == objects[0].getPositions() |
| 38 True | 38 True |
| 39 >>> o2.getPositions() == objects[1].getPositions() | 39 >>> o2.getPositions() == objects[1].getPositions() |
| 40 True | 40 True |
| 41 >>> objects = loadTrajectoriesFromSqlite('test.sqlite', 'feature', timeStep = 2) | |
| 42 >>> objects[0].positions.length() | |
| 43 6 | |
| 44 >>> objects[1].positions.length() | |
| 45 5 | |
| 46 >>> objects = loadTrajectoriesFromSqlite('test.sqlite', 'feature', timeStep = 3) | |
| 47 >>> objects[0].positions.length() | |
| 48 4 | |
| 49 >>> objects[1].positions.length() | |
| 50 4 | |
| 41 >>> align1 = Trajectory.fromPointList([Point(-1, 0), Point(20, 0)]) | 51 >>> align1 = Trajectory.fromPointList([Point(-1, 0), Point(20, 0)]) |
| 42 >>> align2 = Trajectory.fromPointList([Point(-9, -3), Point(6, 3)]) | 52 >>> align2 = Trajectory.fromPointList([Point(-9, -3), Point(6, 3)]) |
| 43 >>> align1.computeCumulativeDistances() | 53 >>> align1.computeCumulativeDistances() |
| 44 >>> align2.computeCumulativeDistances() | 54 >>> align2.computeCumulativeDistances() |
| 45 >>> prepareSplines([align1, align2]) | 55 >>> prepareSplines([align1, align2]) |
