Mercurial Hosting > traffic-intelligence
annotate python/tests/moving_shapely.txt @ 718:2cd245cb780d
added option to set low_memory = False for pandas.read_csv
author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
---|---|
date | Thu, 30 Jul 2015 17:43:14 -0400 |
parents | 6ae68383071e |
children | 7c38250ddfc7 |
rev | line source |
---|---|
635
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
1 >>> from moving import * |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
2 >>> from shapely.geometry import Polygon |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
3 |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
4 >>> t1 = Trajectory([[0.5,1.5,2.5],[0.5,3.5,6.5]]) |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
5 >>> t1.getTrajectoryInPolygon(Polygon([[0,0],[4,0],[4,3],[0,3]])) |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
6 (0.500000,0.500000) |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
7 >>> t1.getTrajectoryInPolygon(Polygon([[10,10],[14,10],[14,13],[10,13]])).length() |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
8 0 |
6ae68383071e
corrected issue with tests requiring shapely, adding a separate test file
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
9 |