-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from cevi/improve-point-selection-algorithm
* Improves the point selection algorithm * Clarifies code documentation
- Loading branch information
Showing
14 changed files
with
413 additions
and
176 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
imgs/ | ||
testWalks/ | ||
output/* | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,18 @@ | ||
# How to run it? | ||
|
||
Make sure you have installed python 3 and all requirements listed in the requirements.txt file. | ||
Now you can run ```main.py``` to launch the script. | ||
Make sure you have installed python 3 and all requirements listed in the requirements.txt file. Now you can | ||
run ```main.py``` to launch the script. The produced files get saved in the ./output directory. | ||
|
||
In the ```main.py``` you can specify the ```DEPARTURE_TIME```, ```GPX_FILE_PATH```, and ```VELOCITY```. Note: the script | ||
is only tested with GPX-files exported form SchweizMobil, but it should work with arbitrary GPX-files. | ||
|
||
## About SwissTopo Services | ||
## About swisstopo Services | ||
|
||
Request limits, see https://www.geo.admin.ch/de/geo-dienstleistungen/geodienste/terms-of-use.html | ||
This script highly depends on the services form swisstopo (Federal Office of Topography swisstopo). Those services are | ||
free-of-charge and do not require registration (since 01.03.2021). However, we should follow there "Fair Use" rules. | ||
More details see [API documentation](https://api3.geo.admin.ch/services/sdiservices.html) | ||
and [Terms of use](https://www.geo.admin.ch/de/geo-dienstleistungen/geodienste/terms-of-use.html). | ||
|
||
Thus, in some cases, e.g. finding a swisstopo name for a coordinate, we will not use the official API but rebuild the | ||
query algorithm locally. Therefore, please make sure, you have downloaded the necessary files in the ./res folder. The | ||
files needed include ```swissNAMES3D_LIN.csv```, ```swissNAMES3D_PKT.csv```, and ```swissNAMES3D_PLY.csv```. |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,18 +28,22 @@ | |
# Aaron Schmocker [[email protected]] | ||
# vim: tabstop=4 shiftwidth=4 softtabstop=4 expandtab | ||
|
||
# Source: http://www.swisstopo.admin.ch/internet/swisstopo/en/home/topics/survey/sys/refsys/projections.html (see PDFs under "Documentation") | ||
# Source: http://www.swisstopo.admin.ch/internet/swisstopo/en/home/topics/survey/sys/refsys/projections.html | ||
# (see PDFs under "Documentation") | ||
# Updated 9 dec 2014 | ||
# Please validate your results with NAVREF on-line service: http://www.swisstopo.admin.ch/internet/swisstopo/en/home/apps/calc/navref.html (difference ~ 1-2m) | ||
|
||
# Please validate your results with NAVREF on-line service: | ||
# http://www.swisstopo.admin.ch/internet/swisstopo/en/home/apps/calc/navref.html (difference ~ 1-2m) | ||
|
||
import math | ||
|
||
|
||
class GPSConverter(object): | ||
''' | ||
|
||
""" | ||
GPS Converter class which is able to perform convertions between the | ||
CH1903 and WGS84 system. | ||
''' | ||
""" | ||
|
||
# Convert CH y/x/h to WGS height | ||
def CHtoWGSheight(self, y, x, h): | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.