Minimal initial data¶
Important
These data are the minimal initial data required to have a functional Geotrek-admin after completing the installation.
Altimetry (DEM)¶
Keywords
DEM, MNT, raster, QGIS
Data sources recommandations
Name |
Provider |
Coverage |
Resolution |
Format |
|---|---|---|---|---|
IGN |
Departmental |
25 m |
|
|
IGN |
Departmental |
1 m or 5 m |
|
Warning
We recommend not importing a DEM with too precise resolution for performance reasons. For example, the BD Alti DEM with a 25m resolution is perfect to cover a department.
If you downloaded the BD Alti or RGE Alti, you will need to convert the
.ascDEM to.tifformat (e.g. with QGIS) before uploading it on the server.
In QGIS, you can visualize your DEM, or merge several tiles together (in Raster > Misc > Merge).
Generate a GeoTIFF, and upload both files (.tif + .tfw) on the server.
And use the Geotrek-admin command to load it into PostGIS :
sudo geotrek loaddem <PATH>/dem.tif
Note
This command makes use of GDAL and
raster2pgsqlinternally. It therefore supports all GDAL raster input formats. You can list these formats with the commandraster2pgsql -G.The elevation data of DEM must be integer values. If the elevation data are floating numbers, you can convert them in integer values with the Raster calculator processing of SAGA in QGis (Processing > Toolbox > SAGA > Raster calculus > Raster calculator) with formula parameter set to
int(a).If you only have a
.tiffile, you can generate the.tfwfile with the commandgdal_translate -co "TFW=YES" in.tif out.tif. It will generate a new.tiffile with its.tfwmetadata file.If you want to update the altimetry of the topologies you need to use the option
--update-altimery
Load DEM¶
Refer to this section to learn how to load DEM with the loaddem command.
Paths¶
Keywords
command line, import en ligne de commande, QGIS
✨ Only available in dynamic segmentation
Important
With dynamic segmentation, importing paths is very risky if paths are already present in the same area in Geotrek, it is only safe for an area where no path is already created.
Indeed, if you import paths where there are existing paths, treks, POIs or trails linked topology might be impacted.
Step 1: Prepare the paths to import¶
By exporting paths from OpenStreetMap¶
You can use the osm-paths tool to download OSM paths data via the overpass API. This tool converts paths into linestrings and exports them to GeoJSON.
For more information, refer to the osm-paths documentation
By using your own paths¶
Requirements¶
Before importing paths layer, it is important to prepare them. Here are the requirements:
valid geometry
simple geometry (no intersection)
all intersections must cut the paths
not double or covering others
Cleaning your paths¶
We use QGis to clean a path layer, with plugin Grass. Here are the operations:
Check the SRID (must be the same as in Geotrek)
Use the Geometric tools:
Go to Vectors → Geometric tools → “Collect geometries”.
Then go to Vectors → Geometric tools → “Group”.
Clean geometries:
Search for v_clean in the Processing toolbox.
Select the following options in the cleaning tool:
break
snap
duplicate (or rmdup)
rmline
rmdangle
chdangle
bpol
prune
In threshold, enter 2,2,2,2,2,2,2,2 (2 meters for each option).
Delete duplicate geometries:
Search for duplicate in the Processing toolbox.
Regroup lines:
Search for v.build.polyline in the Processing toolbox.
Select first in Category number mode.
Step 2: Import the paths into your instance¶
There are two ways to import paths:
importing a file via the command line by using the
loadpathscommand. Refer to this section to learn how to use it
Step 3: Pre-generate the path graph¶
After importing a large quantity of paths, it is recommended to pre-generate the paths graph needed for the routing.
This action is not mandatory, but will reduce the time needed for the first routing following the import.
To pre-generate the graph, use the generate_pgr_network_topology command. Refer to this section to learn about this command.
Areas¶
Cities¶
Data sources recommandations
Name |
Provider |
Coverage |
Scale |
Format |
Update Frequency |
|---|---|---|---|---|---|
Admin Express (COMMUNE) |
IGN |
Metropolitan France, Overseas Territories |
Municipality |
Geopackage, Shapefile |
Annually |
Etalab |
Metropolitan France, Overseas Territories |
Municipality |
GeoJSON |
Annually |
See also
Refer to this section to learn more about loading cities in your Geotrek-admin.
Districts¶
Data sources recommandations
Name |
Provider |
Coverage |
Scale |
Format |
Update Frequency |
|---|---|---|---|---|---|
Admin Express (EPCI) |
IGN |
Metropolitan France, Overseas Territories |
EPCI |
Geopackage, Shapefile |
Annually |
Etalab |
Metropolitan France, Overseas Territories |
EPCI |
GeoJSON |
Annually |
Districts are not necessarily administrative boundaries. They can be intercommunalities, departments, parks, or natural regions. The advantage of importing them as Districts is that you will be able to filter them in Geotrek-rando, which will not be possible with Restricted areas.
See also
Refer to this section to learn more about loading districts in your Geotrek-admin.
Restricted areas¶
Data sources recommandations
Name |
Provider |
Coverage |
Format |
Update Frequency |
|---|---|---|---|---|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
See also
Refer to this section to learn more about loading restricted areas in your Geotrek-admin.
Sensitive areas¶
Data source recommandation
Name |
Provider |
Coverage |
Format |
Update Frequency |
|---|---|---|---|---|
INPN |
Metropolitan France, Overseas Territories |
Shapefile |
Annually |
See also
Refer to this section to learn more about loading sensitive areas in your Geotrek-admin.