Skip to content

Commit

Permalink
added main.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Jay Borseth committed Dec 28, 2023
1 parent 12bcd98 commit e843b49
Show file tree
Hide file tree
Showing 6 changed files with 371 additions and 152 deletions.
54 changes: 53 additions & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,58 @@
"program": "${file}",
"console": "integratedTerminal",
"justMyCode": true
},

{
"name": "help",
"type": "python",
"request": "launch",
"program": "tilepyramidcut/main.py",
"console": "integratedTerminal",
"justMyCode": true,
"args": ["--help"]
},
{
"name": "copy",
"type": "python",
"request": "launch",
"program": "tilepyramidcut/main.py",
"console": "integratedTerminal",
"justMyCode": true,
"args": [
"--src",
"c:/junk/",
"--dst",
"c:/junk2/",
"--op",
"copy",
"--polyfile",
"polygons/test2.json",
"--zbegin",
"3",
"--zend",
"6"
]
},
{
"name": "prune",
"type": "python",
"request": "launch",
"program": "tilepyramidcut/main.py",
"console": "integratedTerminal",
"justMyCode": true,
"args": [
"--src",
"c:/junk/",
"--op",
"prune",
"--polyfile",
"polygons/test2.json",
"--zbegin",
"3",
"--zend",
"6"
]
}
]
}
}
68 changes: 68 additions & 0 deletions polygons/test1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
{
"id": "4187b9f5-0aee-497e-b21d-a67451ecc2c6",
"pk": "",
"name": "unsaved trip",
"type": "trip",
"access": "public",
"bboxPolygon": {
"type": "Feature",
"bbox": [null, null, null, null],
"properties": {},
"geometry": {
"type": "Polygon",
"coordinates": [
[
[null, null],
[null, null],
[null, null],
[null, null],
[null, null]
]
]
}
},
"events": {
"pre": [],
"during": [],
"post": []
},
"featureCollection": {
"type": "FeatureCollection",
"features": [
{
"id": "581486ab552bc6495318301f65570213",
"type": "Feature",
"properties": {
"isRoute": true,
"name": "route 1",
"color": "#ff0000",
"isVisible": true,
"length": 387.73835,
"colorOuter": "#FFFFFF",
"speed": 6,
"departureTime": "2023-12-26T17:57:21.000Z",
"arrivalTime": "2023-12-29T10:34:44.008Z"
},
"geometry": {
"coordinates": [
[-122.6223, 48.39416],
[-124.79846, 48.49026],
[-125.00316, 47.39116],
[-124.3922, 46.79512],
[-122.18454, 46.89421],
[-121.87906, 47.85601],
[-122.58451, 48.34604]
],
"type": "LineString"
}
}
],
"bbox": [null, null, null, null]
},
"routeCount": 1,
"routesTotalLength": 387.73835,
"routesTotalDurationInDays": 2.69263,
"markerCount": 0,
"trackCount": 0,
"tracksTotalLength": 0
}
106 changes: 106 additions & 0 deletions polygons/test2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
{
"id": "fccea74f-b0d2-4776-ace9-230efb268857",
"pk": "aee7a7a3-f582-45b6-9532-58455576b51a",
"name": "unsaved trip",
"type": "trip",
"access": "public",
"bboxPolygon": {
"type": "Feature",
"bbox": [179.38246, 16.20065, -32.83598, 56.71573],
"properties": {},
"geometry": {
"type": "Polygon",
"coordinates": [
[
[179.38246, 16.20065],
[-32.83598, 16.20065],
[-32.83598, 56.71573],
[179.38246, 56.71573],
[179.38246, 16.20065]
]
]
}
},
"events": {
"pre": [],
"during": [],
"post": []
},
"featureCollection": {
"type": "FeatureCollection",
"features": [
{
"id": "8e69d14e5895936592f944f1cdd6b8ca",
"type": "Feature",
"properties": {
"isRoute": true,
"name": "route 1",
"color": "#ff0000",
"isVisible": true,
"length": 7014.20327,
"colorOuter": "#FFFFFF",
"speed": 2,
"departureTime": "2023-12-27T21:54:00.000Z",
"arrivalTime": "2024-01-03T13:18:49.358Z",
"isEnabled": true,
"endPointSelected": 0
},
"geometry": {
"coordinates": [
[-163.34754, 53.87677],
[-136.00337, 56.71573],
[-114.60775, 46.39473],
[-120.94008, 18.76274],
[-165.55056, 41.37076],
[-163.34754, 53.47896]
],
"type": "LineString"
}
},
{
"id": "9bf0460245cfca621f028c4239b512ea",
"type": "Feature",
"properties": {
"isRoute": true,
"name": "route 2",
"color": "#ff0000",
"isVisible": true,
"length": 4928.07837,
"colorOuter": "#FFFFFF",
"speed": 2,
"departureTime": "2024-02-03T21:54:00.000Z",
"arrivalTime": "2024-05-16T13:56:21.059Z",
"isEnabled": true,
"routeMode": "normal",
"geometryOriginal": {
"coordinates": [
[-53.3681, 42.77488],
[-32.83598, 27.06017],
[-49.72221, 16.20065],
[-69.96649, 29.0917],
[-55.47888, 42.06662]
],
"type": "LineString"
}
},
"geometry": {
"coordinates": [
[-53.3681, 42.77488],
[-32.83598, 27.06017],
[-49.72221, 16.20065],
[-69.96649, 29.0917],
[-55.47888, 42.06662]
],
"type": "LineString"
}
}
],
"bbox": [-180.61754, 16.20065, -32.83598, 56.71573]
},
"routeCount": 2,
"routesTotalLength": 11942.28164,
"routesTotalDurationInDays": 140.6683,
"markerCount": 0,
"trackCount": 0,
"tracksTotalLength": 0
}
Empty file added tilepyramidcut/__init__.py
Empty file.
Loading

0 comments on commit e843b49

Please sign in to comment.