Commit 958fde5a authored by Eric Duminil's avatar Eric Duminil
Browse files

More documentation for add_trees

parent aaca2ec3
......@@ -26,25 +26,39 @@ import geopandas as gpd
from tree import Forest
from import_existing_trees import get_existing_forest
# TODO: Use Args
# TODO: Document
# TODO: Write issue
# TODO: Write tests?
# From RegionChooser, or https://transfer.hft-stuttgart.de/gitlab/circulargreensimcity/circulargreensimcity/-/wikis/Fallstudien/Gromb%C3%BChl
WKT = "POLYGON((9.947021 49.803063, 9.947011 49.800917, 9.955025 49.800810, 9.955110 49.803019, 9.947021 49.803063))"
# Grafenbühl
################################################################################
# USER PARAMETERS #
################################################################################
########################
# REGION #
########################
# From RegionChooser, or https://wktmap.com/
# Case-study for Grombühl Paper. (4 Blocks):
WKT = "POLYGON((9.942183 49.804010, 9.942301 49.802740, 9.945477 49.802698, 9.945563 49.804014, 9.942167 49.804055, 9.942183 49.804010))"
# Grafenbühl:
# WKT = "POLYGON((9.147551 48.908059, 9.148635 48.907953, 9.149525 48.907819, 9.151177 48.907819, 9.151413 48.907840, 9.153226 48.908087, 9.153387 48.906705, 9.149160 48.906634, 9.148999 48.906620, 9.147551 48.908059))"
# Replace with None if no existing tree should be imported
EXISTING_TREES = 'existing_trees/Trees_ideal_2_20240227.shp'
# EXISTING_TREES = 'existing_trees/baumkataster/Baum.shp'
########################
# TREES #
########################
EXISTING_TREES = 'existing_trees/baumkataster/Baum.shp'
# Replace with None if no existing tree should be imported.
# EXISTING_TREES = None
# NOTE: Should be the same for Shapefile and the CityGML the trees will be imported to.
EPSG_ID = 25832
# Trees will be planted every TREE_DISTANCE along roads:
TREE_DISTANCE = 10 # [m]
TREE_DISTANCE = 25 # [m]
# Unless there's already another tree closer than MIN_DISTANCE away:
MIN_DISTANCE = TREE_DISTANCE * 0.5 # [m]
# For display purposes only:
GRID = 100 # [m]
MIN_DISTANCE = 10 # [m]
########################
# STREETS #
########################
# If streets from OSM don't have known width, which one should be used? In [m]
# Leave empty to get default from similar streets, if available
# Set to -1 if you want to disable trees along the roads
......@@ -55,6 +69,18 @@ DEFAULT_WIDTHS = {
# 'trunk': -1,
}
# For display purposes only:
GRID = 100 # [m]
################################################################################
# SCRIPT. Probably no need to change anything below. #
################################################################################
# TODO: Use Args
# TODO: Document
# TODO: Write issue
# TODO: Write tests?
SCRIPT_DIR = Path(__file__).resolve().parent
OUTPUT_DIR = SCRIPT_DIR / 'output'
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment