Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Dockerfile and docker-compose.yml #14

Merged
merged 115 commits into from
Sep 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
115 commits
Select commit Hold shift + click to select a range
bd0bcaf
Add GitHub action for SonarQube
acerioni Mar 13, 2023
080780a
Add sonar-project.properties
acerioni Mar 13, 2023
51948a5
Remove unused variable
acerioni Mar 14, 2023
918118a
Enable server certificate validation on SSL/TLS connection
acerioni Mar 14, 2023
880a0f2
Define DEMO_MSG constant in order to avoid duplication
acerioni May 24, 2023
7ebf10a
Introduce LabelOverflowException
acerioni May 24, 2023
ae79029
ACheck and extract x, y, z coordinates from tile IDs at once
acerioni May 24, 2023
507ae22
Do not ignore insecure request warnings
acerioni May 24, 2023
1854473
Remove unused imports
acerioni May 24, 2023
35e7ae2
Introduce and handle custom exceptions for the COCO module
acerioni May 24, 2023
ea530c8
Remove unexpected argument in logger.warning call
acerioni May 24, 2023
c152550
Use specific exception instead of a generic one. Rename variables sta…
acerioni May 24, 2023
5564576
Introduce and handle custom exceptions. Rename variables starting wit…
acerioni May 24, 2023
3b7114f
Rename _PolyArea method as _compute_polygon_area
acerioni May 24, 2023
0e95411
Remove TODO messages
acerioni May 24, 2023
fcc0f3f
Introduce BadFileExtensionException and UnsupportedImageFormatException
acerioni May 24, 2023
52d0c7f
Use custom exception "BadFileExtensionException"
acerioni May 24, 2023
6c1a6a0
Rename variables in order to comply with Python naming conventions
acerioni May 24, 2023
42a4782
Remove useless f-strings
acerioni May 24, 2023
925c279
Add SCATTER_PLOT_MODE constant
acerioni May 24, 2023
af51109
Update requirements.in and requirements.txt in order to faddress Depe…
acerioni May 24, 2023
b17d22d
Remove extra blank space. Use "md_filename" variable instead of equiv…
acerioni May 24, 2023
fb49467
Ignore UserWarning, cf. https://github.com/facebookresearch/detectron…
acerioni May 25, 2023
ab66817
Remove useless imports
acerioni May 25, 2023
6e2d3b5
Remove commented-out line
acerioni May 25, 2023
c645f3d
Better handle constants (e.g. DONE_MSG)
acerioni May 25, 2023
7b82c40
Remove useless imports
acerioni May 25, 2023
1bbb612
Use loguru instead of logging
acerioni May 25, 2023
2e6da72
Fix XYZ connector
acerioni Jul 28, 2023
9360c36
Add setup.py and adapt scripts to be used as console scripts
acerioni Aug 4, 2023
bd9f95d
Update setup.py
acerioni Aug 4, 2023
bb32f12
Remove commented out line
acerioni Aug 7, 2023
3846063
Make version number compliant with PEP 440
acerioni Aug 14, 2023
45fb811
Add CLI with tasks as subcommands
acerioni Aug 16, 2023
2089b6e
Prevent the CLI from raising an exception in case no argument is passed
acerioni Aug 30, 2023
ed1fe42
Add detectron2 config file
cleherny Aug 31, 2023
bad71e3
Add trne config file
cleherny Aug 31, 2023
ffe6596
Add config-prd file
cleherny Aug 31, 2023
a331de6
Add logging.conf file
cleherny Aug 31, 2023
fdcfa51
Add prepare_data.py
cleherny Aug 31, 2023
631b08e
Add prediction_filter.py script
cleherny Aug 31, 2023
1a7a831
Adapt paths in config files
cleherny Aug 31, 2023
1a26ef8
Add morecantile to requirements
cleherny Aug 31, 2023
13c13d7
Add input data (label shp and AOI 2021 shp
cleherny Aug 31, 2023
1d45022
Running version of the quarry example with packages in requirements.txt
cleherny Aug 31, 2023
f9537d2
Correct packages version in requirements.in
cleherny Aug 31, 2023
1776ba7
Change name of prediction filter script
cleherny Aug 31, 2023
e3e2f19
Update package version in requirements.in
cleherny Aug 31, 2023
30c4ea7
Add README.md file
cleherny Aug 31, 2023
a0d1105
Rename config files
cleherny Aug 31, 2023
5f074bc
Fix scikit-learn version
cleherny Aug 31, 2023
e435fc5
Remove logging.conf file (deprecated)
acerioni Sep 8, 2023
47f1bfb
Generate tiles straight in EPSG:4326
acerioni Sep 8, 2023
b9eb3ad
Improve code style for iteration over label boundaries. Avoid useless…
acerioni Sep 8, 2023
940b534
Improve code readability
acerioni Sep 8, 2023
46b3e9a
Fix some comments and screen outputs
acerioni Sep 8, 2023
84c3cbb
Improve code generating tile IDs
acerioni Sep 8, 2023
094f217
Remove unused import (tqdm)
acerioni Sep 8, 2023
b792545
Fix tile ID format
acerioni Sep 8, 2023
9a08ad3
Comment/delete unused code
acerioni Sep 8, 2023
80c1333
Add Dockerfile and docker-compose.yml
acerioni Sep 8, 2023
6de3b86
Update README.md for quarry example
cleherny Sep 11, 2023
0451395
Remove requirements info from README of the quarry example
cleherny Sep 11, 2023
bfd7ddb
Merge pull request #16 from swiss-territorial-data-lab/ch/add-docker
acerioni Sep 11, 2023
de622da
Rename tasks -> stages
acerioni Sep 12, 2023
e4821e7
Update README.md
acerioni Sep 12, 2023
a297b98
Install python-is-python3
acerioni Sep 12, 2023
e336325
Use nobody user inside the container
acerioni Sep 12, 2023
6be9836
Add logger.success and done msg function
cleherny Sep 12, 2023
8580323
Rename filter file name to filter_detection.py
cleherny Sep 12, 2023
e049593
Replace - by _ in output folder names
cleherny Sep 12, 2023
2e649be
Update examples/swimming-pool-detection/GE/README.md
acerioni Sep 12, 2023
ee634d6
Update examples/swimming-pool-detection/NE/README.md
acerioni Sep 12, 2023
470a859
Update examples/quarry-detection/README.md
acerioni Sep 12, 2023
9f16282
repo -> repository
acerioni Sep 12, 2023
622c38e
Correct filter name in config_prd
cleherny Sep 12, 2023
96eb8ba
Improve prompt comments
cleherny Sep 12, 2023
e40342b
Merge branch 'ac/add-docker' into ch/logger_improvement
cleherny Sep 12, 2023
0ca7c41
Update README.md
cleherny Sep 12, 2023
22f4cc0
Add -it to docker compose command line in READMEs
cleherny Sep 12, 2023
db3b582
Add bash script to dl and reproject swiss dem
cleherny Sep 13, 2023
49a0c42
Fixed how-to TOC broken link
cleherny Sep 13, 2023
2c206c2
Add warning for pip install .
cleherny Sep 13, 2023
3267495
Add command to get back write permission on te created files to swimm…
cleherny Sep 13, 2023
12b228a
Correct import style PEP8 ref in scripts folder
cleherny Sep 13, 2023
7b6a370
Change detections to predictions in quarry example to match swimming …
cleherny Sep 13, 2023
e8e273d
Add missing bash command in README.md command lines
cleherny Sep 13, 2023
ed96a5c
Correct comma typo in the main README
cleherny Sep 13, 2023
12e33a1
Correct AOI to AoI in quarry example
cleherny Sep 14, 2023
037ed5f
Correct AOI to AoI in swinning-pool examples
cleherny Sep 14, 2023
0b82363
Merge pull request #17 from swiss-territorial-data-lab/ch/dl_dem
acerioni Sep 14, 2023
1bdf275
Set MPLCONFIGDIR env variable to a writable directory
acerioni Sep 14, 2023
dda49b1
Improve README.md concerning Python venvs and editable installs
acerioni Sep 14, 2023
ead4f4f
Minor improvements
acerioni Sep 15, 2023
d4f5d33
Imports on separate lines in order to comply with PEP 8
acerioni Sep 15, 2023
21e2dd3
Fix path to file
acerioni Sep 15, 2023
321ee1b
Merge branch 'master' into ac/add-docker
cleherny Sep 15, 2023
85bf5e5
Correct links + change predictions to detections
cleherny Sep 15, 2023
8b99d25
Change predictions to detections in examples READMEs
cleherny Sep 15, 2023
627a5da
Remove file
acerioni Sep 15, 2023
1a6f197
Change predictions to detections in scripts folder
cleherny Sep 15, 2023
635c6b7
Delete duplicate filter predictions script
cleherny Sep 15, 2023
b093799
Change prediction to detection for filter script
cleherny Sep 15, 2023
8c27f6c
Change predictions to detections in config files
cleherny Sep 15, 2023
e00ca11
Add exit command to swimming pool READMEs
cleherny Sep 15, 2023
b52cfd2
Change predictions to detection in cli file
cleherny Sep 15, 2023
5a1774b
Rename predictions -> detections
acerioni Sep 15, 2023
9780869
Change predictions to detections in functions
cleherny Sep 15, 2023
16c0fa2
Merge with branch ac/rename
cleherny Sep 15, 2023
c2f8805
Correct function name in make_detections
cleherny Sep 15, 2023
76d37e3
Add link to swissimage time traval
cleherny Sep 15, 2023
85d7577
Correct error in function name of train model
cleherny Sep 15, 2023
423eb5c
Merge pull request #19 from swiss-territorial-data-lab/ch/correction-…
acerioni Sep 15, 2023
7f6d1d7
Replace link to external info on Slippy Map Tiles with an active one
acerioni Sep 15, 2023
81a0e6b
Merge pull request #18 from swiss-territorial-data-lab/ac/rename-pred…
cleherny Sep 15, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM nvidia/cuda:11.3.1-runtime-ubuntu20.04

RUN apt update &&\
apt upgrade -y &&\
apt install -y libgl1 &&\
apt install -y libglib2.0-0 &&\
apt install -y gdal-bin &&\
apt install -y wget &&\
apt install -y python3-pip &&\
apt install -y python-is-python3

WORKDIR /app

ADD requirements.txt .
RUN pip install -r requirements.txt --no-cache-dir

ADD helpers/*.py helpers/
ADD scripts/*.py scripts/

ADD setup.py .
RUN pip install .

USER 65534:65534

ENV MPLCONFIGDIR /tmp

ENTRYPOINT [""]
CMD ["stdl-objdet", "-h"]
235 changes: 146 additions & 89 deletions README.md

Large diffs are not rendered by default.

15 changes: 15 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
version: "3"

services:
stdl-objdet:
build: .
volumes:
- ./examples:/app/examples
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
command: /bin/bash
58 changes: 31 additions & 27 deletions examples/quarry-detection/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,38 +3,42 @@
A sample working setup is provided here, enabling the end-user to detect quarries and mineral extraction sites in Switzerland over several years. <br>
It consists of the following elements:

- the read-to-use configuration files:
- `config_trne.yaml`,
- `config_prd.yaml`,
- `detectron2_config_dqry.yaml`,
- the input data in the `data` subfolder:
- quarries shapefile from the product [swissTLM3D](https://www.swisstopo.admin.ch/fr/geodata/landscape/tlm3d.html), revised and synchronised with the 2020 [SWISSIMAGE](https://www.swisstopo.admin.ch/fr/geodata/images/ortho/swissimage10.html) mosaic (**label**),
- the delimitation of the AOI to perform inference predictions (**AOI**),
- the swiss DEM raster is too large to be saved on this platform but can be downloaded from this [link](https://github.com/lukasmartinelli/swissdem) using the EPSG:4326 - WGS 84 coordinate reference system. The raster must be first reprojected to EPSG:2056 - CH1903+ / LV95, named `switzerland_dem_EPSG2056.tif`and located in the **DEM** subfolder.
- a data preparation script (`prepare_data.py`) producing the files to be used as input to the `generate_tilesets.py`script.
- a results post-processing script (`filter_prediction.py`) filtering the predictions, produced from `make_prediction.py`script, to the final shapefile

After creating and a new environment in python 3.8, the end-to-end workflow can be run by issuing the following list of commands, straight from this folder:

```bash
$ sudo apt-get install -y python3-gdal gdal-bin libgdal-dev gcc g++ python3.8-dev
$ pip install -r ../../requirements.txt
$ python3 prepare_data.py config_trne.yaml
$ python3 ../../scripts/generate_tilesets.py config_trne.yaml
$ python3 ../../scripts/train_model.py config_trne.yaml
$ python3 ../../scripts/make_predictions.py config_trne.yaml
$ python3 ../../scripts/assess_predictions.py config_trne.yaml
$ python3 prepare_data.py config_prd.yaml
$ python3 ../../scripts/generate_tilesets.py config_prd.yaml
$ python3 ../../scripts/make_predictions.py config_prd.yaml
$ python3 filter_detection.py config_prd.yaml
- ready-to-use configuration files:
- `config_trne.yaml`;
- `config_prd.yaml`;
- `detectron2_config_dqry.yaml`.
- Input data in the `data` subfolder:
- quarry **labels** issued from the [swissTLM3D](https://www.swisstopo.admin.ch/fr/geodata/landscape/tlm3d.html) product, revised and synchronized with the 2020 [SWISSIMAGE](https://www.swisstopo.admin.ch/fr/geodata/images/ortho/swissimage10.html) orthophotos;
- the delimitation of the **Area of Interest (AoI)**;
- the Swiss DEM raster is too large to be saved on this platform but can be downloaded from this [link](https://github.com/lukasmartinelli/swissdem) using the [EPSG:4326](https://epsg.io/4326) coordinate reference system. The raster must be re-projected to [EPSG:2056](https://epsg.io/2056), renamed as `switzerland_dem_EPSG2056.tif` and located in the **DEM** subfolder. This procedure is managed by running the bash script `get_dem.sh`.
- A data preparation script (`prepare_data.py`) producing the files to be used as input to the `generate_tilesets` stage.
- A post-processing script (`filter_detections.py`) which filters detections according to their confidence score, altitude and area. The script also identifies and merges groups of nearby polygons.

The workflow can be run end-to-end by issuing the following list of commands, from the root folder of this GitHub repository:

```
$ sudo chown -R 65534:65534 examples
$ docker compose run --rm -it stdl-objdet
nobody@<id>:/app# cd examples/quarry-detection
nobody@<id>:/app# python prepare_data.py config_trne.yaml
nobody@<id>:/app# stdl-objdet generate_tilesets config_trne.yaml
nobody@<id>:/app# stdl-objdet train_model config_trne.yaml
nobody@<id>:/app# stdl-objdet make_detections config_trne.yaml
nobody@<id>:/app# stdl-objdet assess_detections config_trne.yaml
nobody@<id>:/app# python prepare_data.py config_prd.yaml
nobody@<id>:/app# stdl-objdet generate_tilesets config_prd.yaml
nobody@<id>:/app# stdl-objdet make_detections config_prd.yaml
nobody@<id>:/app# bash get_dem.sh
nobody@<id>:/app# python filter_detections.py config_prd.yaml
nobody@<id>:/app# exit
$ sudo chmod -R a+w examples
```

We strongly encourage the end-user to review the provided `config_trne.yaml` and `config_prd.yaml` files as well as the various output files, a list of which is printed by each script before exiting.

The model is trained on the 2020 [SWISSIMAGE](https://www.swisstopo.admin.ch/fr/geodata/images/ortho/swissimage10.html) mosaic. Inference can be performed on SWISSIMAGE mosaics of the product SWISSIMAGE time travel by changing the year in `config_prd.yaml`. It should be noted that the model has been trained on RGB color images and might not perform as well on Black and White images.
The model is trained on the 2020 [SWISSIMAGE](https://www.swisstopo.admin.ch/fr/geodata/images/ortho/swissimage10.html) mosaic. Inference can be performed on SWISSIMAGE mosaics of the product [SWISSIMAGE time travel](https://map.geo.admin.ch/?lang=en&topic=swisstopo&bgLayer=ch.swisstopo.pixelkarte-farbe&zoom=0&layers_timestamp=2004,2004,&layers=ch.swisstopo.swissimage-product,ch.swisstopo.swissimage-product.metadata,ch.swisstopo.images-swissimage-dop10.metadata&E=2594025.91&N=1221065.68&layers_opacity=1,0.7,1&time=2004&layers_visibility=true,true,false) by changing the year in `config_prd.yaml`. It should be noted that the model has been trained on RGB images and might not perform as well on B&W images.

For more information about this project, you can consult [the associated repository](https://github.com/swiss-territorial-data-lab/proj-dqry) (not public yet).
For more information about this project, see [this repository](https://github.com/swiss-territorial-data-lab/proj-dqry) (not public yet).

## Disclaimer

Expand Down
32 changes: 16 additions & 16 deletions examples/quarry-detection/config_prd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,25 @@
####### Inference detection #######
# Automatic detection of Quarries and Mineral Extraction Sites (MES) in images

# 1-Produce tiles geometry according to the AOI extent and zoom level
# 1-Produce tiles geometry according to the AoI extent and zoom level
prepare_data.py:
srs: "EPSG:2056" # Projection of the input file
datasets:
labels_shapefile: ./data/AOI/AOI_2020.shp
output_folder: ./output/output-prd
labels_shapefile: ./data/AoI/AoI_2020.shp
output_folder: ./output/output_prd
zoom_level: 16

# 2-Fetch of tiles (online server) and split into 3 datasets: train, test, validation
generate_tilesets.py:
debug_mode: False # sample of tiles
datasets:
aoi_tiles_geojson: ./output/output-prd/tiles.geojson
aoi_tiles_geojson: ./output/output_prd/tiles.geojson
orthophotos_web_service:
type: XYZ # supported values: 1. MIL = Map Image Layer 2. WMS 3. XYZ
url: https://wmts.geo.admin.ch/1.0.0/ch.swisstopo.swissimage-product/default/2020/3857/{z}/{x}/{y}.jpeg
output_folder: ./output/output-prd
output_folder: ./output/output_prd
tile_size: 256 # per side, in pixels
overwrite: True
overwrite: False
n_jobs: 10
COCO_metadata:
year: 2021
Expand All @@ -36,29 +36,29 @@ generate_tilesets.py:
supercategory: "Land usage"

# 3-Perform the object detection based on the optimized trained model
make_predictions.py:
working_folder: ./output/output-prd
make_detections.py:
working_folder: ./output/output_prd
log_subfolder: logs
sample_tagged_img_subfolder: sample_tagged_images
COCO_files: # relative paths, w/ respect to the working_folder
oth: COCO_oth.json
detectron2_config_file: '../../detectron2_config_dqry.yaml' # path relative to the working_folder
model_weights:
pth_file: '../output-trne/logs/model_0002999.pth' # trained model minimizing the validation loss curve, monitor the training process via tensorboard (tensorboard --logdir </logs>)
image_metadata_json: './output/output-prd/img_metadata.json'
pth_file: '../output_trne/logs/model_0002999.pth' # trained model minimizing the validation loss curve, monitor the training process via tensorboard (tensorboard --logdir </logs>)
image_metadata_json: './output/output_prd/img_metadata.json'
rdp_simplification: # rdp = Ramer-Douglas-Peucker
enabled: True
epsilon: 2.0 # cf. https://rdp.readthedocs.io/en/latest/
score_lower_threshold: 0.3

# 4-Filtering and merging prediction polygons to improve results
filter_prediction.py:
# 4-Filtering and merging detection polygons to improve results
filter_detections.py:
year: 2020
input: ./output/output-prd/oth_predictions_at_0dot3_threshold.gpkg
labels_shapefile: ./data/AOI/AOI_2020.shp
input: ./output/output_prd/oth_detections_at_0dot3_threshold.gpkg
labels_shapefile: ./data/AoI/AoI_2020.shp
dem: ./data/DEM/switzerland_dem_EPSG2056.tif
elevation: 1200.0 # m, altitude threshold
score: 0.95 # prediction score (from 0 to 1) provided by detectron2
score: 0.95 # detection score (from 0 to 1) provided by detectron2
distance: 10 # m, distance use as a buffer to merge close polygons (likely to belong to the same object) together
area: 5000.0 # m2, area threshold under which polygons are discarded
output: ./output/output-prd/oth_prediction_at_0dot3_threshold_year-{year}_score-{score}_area-{area}_elevation-{elevation}_distance-{distance}.geojson
output: ./output/output_prd/oth_detections_at_0dot3_threshold_year-{year}_score-{score}_area-{area}_elevation-{elevation}_distance-{distance}.geojson
38 changes: 19 additions & 19 deletions examples/quarry-detection/config_trne.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,24 @@
####### Model training and evaluation #######
# Training of automatic detection of Quarries and Mineral Extraction Sites (MES) in images with a provided ground truth

# 1-Produce tiles geometry according to the AOI extent and zoom level
# 1-Produce tiles geometry according to the AoI extent and zoom level
prepare_data.py:
srs: "EPSG:2056"
datasets:
labels_shapefile: ./data/labels/tlm-hr-trn-topo.shp
output_folder: ./output/output-trne
output_folder: ./output/output_trne
zoom_level: 16

# 2-Fetch of tiles (online server) and split into 3 datasets: train, test, validation
generate_tilesets.py:
debug_mode: False # sample of tiles
datasets:
aoi_tiles_geojson: ./output/output-trne/tiles.geojson
ground_truth_labels_geojson: ./output/output-trne/labels.geojson
aoi_tiles_geojson: ./output/output_trne/tiles.geojson
ground_truth_labels_geojson: ./output/output_trne/labels.geojson
orthophotos_web_service:
type: XYZ # supported values: 1. MIL = Map Image Layer 2. WMS 3. XYZ
url: https://wmts.geo.admin.ch/1.0.0/ch.swisstopo.swissimage-product/default/2020/3857/{z}/{x}/{y}.jpeg
output_folder: ./output/output-trne
output_folder: ./output/output_trne
tile_size: 256 # per side, in pixels
overwrite: False
n_jobs: 10
Expand All @@ -38,7 +38,7 @@ generate_tilesets.py:

# 3-Train the model with the detectron2 algorithm
train_model.py:
working_folder: ./output/output-trne
working_folder: ./output/output_trne
log_subfolder: logs
sample_tagged_img_subfolder: sample_tagged_images
COCO_files: # relative paths, w/ respect to the working_folder
Expand All @@ -50,8 +50,8 @@ train_model.py:
model_zoo_checkpoint_url: "COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_1x.yaml"

# 4-Perform the object detection based on the optimized trained model
make_predictions.py:
working_folder: ./output/output-trne
make_detections.py:
working_folder: ./output/output_trne
log_subfolder: logs
sample_tagged_img_subfolder: sample_tagged_images
COCO_files: # relative paths, w/ respect to the working_folder
Expand All @@ -61,20 +61,20 @@ make_predictions.py:
detectron2_config_file: '../../detectron2_config_dqry.yaml' # path relative to the working_folder
model_weights:
pth_file: './logs/model_0002999.pth' # trained model minimizing the validation loss curve, monitor the training process via tensorboard (tensorboard --logdir </logs>)
image_metadata_json: './output/output-trne/img_metadata.json'
image_metadata_json: './output/output_trne/img_metadata.json'
rdp_simplification: # rdp = Ramer-Douglas-Peucker
enabled: true
epsilon: 2.0 # cf. https://rdp.readthedocs.io/en/latest/
score_lower_threshold: 0.05

# 5-Evaluate the quality of the prediction for the different datasets with metrics calculation
assess_predictions.py:
# 5-Evaluate the quality of the detections for the different datasets with metrics calculation
assess_detections.py:
datasets:
ground_truth_labels_geojson: ./output/output-trne/labels.geojson
image_metadata_json: ./output/output-trne/img_metadata.json
split_aoi_tiles_geojson: ./output/output-trne/split_aoi_tiles.geojson # aoi = Area of Interest
predictions:
trn: ./output/output-trne/trn_predictions_at_0dot05_threshold.gpkg
val: ./output/output-trne/val_predictions_at_0dot05_threshold.gpkg
tst: ./output/output-trne/tst_predictions_at_0dot05_threshold.gpkg
output_folder: ./output/output-trne
ground_truth_labels_geojson: ./output/output_trne/labels.geojson
image_metadata_json: ./output/output_trne/img_metadata.json
split_aoi_tiles_geojson: ./output/output_trne/split_aoi_tiles.geojson # aoi = Area of Interest
detections:
trn: ./output/output_trne/trn_detections_at_0dot05_threshold.gpkg
val: ./output/output_trne/val_detections_at_0dot05_threshold.gpkg
tst: ./output/output_trne/tst_detections_at_0dot05_threshold.gpkg
output_folder: ./output/output_trne
1 change: 1 addition & 0 deletions examples/quarry-detection/data/AoI/AoI_2020.cpg
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
UTF-8
Binary file added examples/quarry-detection/data/AoI/AoI_2020.dbf
Binary file not shown.
1 change: 1 addition & 0 deletions examples/quarry-detection/data/AoI/AoI_2020.prj
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
PROJCS["CH1903+_LV95",GEOGCS["GCS_CH1903+",DATUM["D_CH1903+",SPHEROID["Bessel_1841",6377397.155,299.1528128]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Hotine_Oblique_Mercator_Azimuth_Center"],PARAMETER["False_Easting",2600000.0],PARAMETER["False_Northing",1200000.0],PARAMETER["Scale_Factor",1.0],PARAMETER["Azimuth",90.0],PARAMETER["Longitude_Of_Center",7.43958333333333],PARAMETER["Latitude_Of_Center",46.9524055555556],UNIT["Meter",1.0]]
Binary file added examples/quarry-detection/data/AoI/AoI_2020.shp
Binary file not shown.
Binary file added examples/quarry-detection/data/AoI/AoI_2020.shx
Binary file not shown.
Loading
Loading