From 3091597d8f0e9ea29da9249b8da194c9667a78cd Mon Sep 17 00:00:00 2001 From: Manuel-Knepper Date: Wed, 27 May 2026 10:16:29 +0200 Subject: [PATCH 1/2] prep files for new release --- .release-please-manifest.json | 2 +- CITATION.cff | 4 ++-- README.md | 2 +- docs/changelog.md | 5 +++++ docs/conf.py | 2 +- fixbikenet/_version.py | 2 +- pyproject.toml | 2 +- 7 files changed, 12 insertions(+), 7 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 2aca35a..4208b5c 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.5.0" + ".": "0.6.0" } \ No newline at end of file diff --git a/CITATION.cff b/CITATION.cff index bb21753..2ba176a 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -9,8 +9,8 @@ authors: - family-names: "Szell" given-names: "Michael" title: "FixBikeNet" -version: 0.5.0 -date-released: 2026-05-06 +version: 0.6.0 +date-released: 2026-05-27 url: "https://github.com/BikeNetKit/FixBikeNet" preferred-citation: type: article diff --git a/README.md b/README.md index ebb04e4..4bcfabd 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ The software downloads and pre-processes data from OpenStreetMap, identifies the ### The easy way > [!IMPORTANT] -> As of 2026-05-06, the conda-forge installation is not yet working. We will remove this note once it works. +> As of 2026-05-27, the conda-forge installation is not yet working. We will remove this note once it works. The best way to install FixBikeNet is using [`conda`](https://docs.conda.io/projects/conda/en/latest/index.html) and the `conda-forge` channel: diff --git a/docs/changelog.md b/docs/changelog.md index a7994ad..65a38c2 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,3 +1,8 @@ +## Version 0.6.0 (2026-05-27) + +- 🔧 fix for config.yml in package +- 🔧 solve issues when highway type not in config + ## Version 0.5.0 (2026-05-06) - ✨Initial release ✨ diff --git a/docs/conf.py b/docs/conf.py index c7e596f..120721e 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -20,7 +20,7 @@ import fixbikenet # noqa # version = growbikenet.__version__ -version = "0.5.0" +version = "0.6.0" release = version # Add any Sphinx extension module names here, as strings. They can be diff --git a/fixbikenet/_version.py b/fixbikenet/_version.py index 71ccc56..7f434f0 100644 --- a/fixbikenet/_version.py +++ b/fixbikenet/_version.py @@ -1,3 +1,3 @@ """fixbikenet package version.""" -__version__ = "0.5.0" # x-release-please-version \ No newline at end of file +__version__ = "0.6.0" # x-release-please-version \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index ba27856..ab0ed9d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "fixbikenet" -version = "0.5.0" +version = "0.6.0" authors = [ { name = "Manuel Knepper" }, { name = "Anastassia Vybornova" }, From a8d00cad8db34ad54a9642f0b21e0b5da04a3d4f Mon Sep 17 00:00:00 2001 From: Manuel-Knepper Date: Wed, 27 May 2026 11:25:51 +0200 Subject: [PATCH 2/2] added config.py and integrated it in functions.py, removed config_osm.yml --- fixbikenet/__init__.py | 1 + fixbikenet/config.py | 24 ++++++++++++++++++++++++ fixbikenet/config/config_osm.yml | 23 ----------------------- fixbikenet/functions.py | 8 ++------ 4 files changed, 27 insertions(+), 29 deletions(-) create mode 100644 fixbikenet/config.py delete mode 100644 fixbikenet/config/config_osm.yml diff --git a/fixbikenet/__init__.py b/fixbikenet/__init__.py index 32cc9d7..d42a04c 100644 --- a/fixbikenet/__init__.py +++ b/fixbikenet/__init__.py @@ -1,6 +1,7 @@ import contextlib from importlib.metadata import PackageNotFoundError, version +from . import config from . import functions from fixbikenet.fixbikenet import fixbikenet diff --git a/fixbikenet/config.py b/fixbikenet/config.py new file mode 100644 index 0000000..3d75a5c --- /dev/null +++ b/fixbikenet/config.py @@ -0,0 +1,24 @@ +protected_bike_infra = { + 'busway': 0, + 'corridor': 0, + 'cycleway': 0, + 'elevator': 1, + 'footway': 1, + 'living_street': 1, + 'motorway': 0, + 'motorway_link': 0, + 'path': 1, + 'pedestrian': 0, + 'primary': 0, + 'primary_link': 0, + 'residential': 0, + 'secondary': 0, + 'secondary_link': 0, + 'service': 0, + 'steps': 0, + 'tertiary': 0, + 'tertiary_link': 0, + 'track': 1, + 'trunk': 0, + 'unclassified': 0 +} \ No newline at end of file diff --git a/fixbikenet/config/config_osm.yml b/fixbikenet/config/config_osm.yml deleted file mode 100644 index 68bf1dc..0000000 --- a/fixbikenet/config/config_osm.yml +++ /dev/null @@ -1,23 +0,0 @@ -protected_bike_infra: - 'busway': 0 - 'corridor': 0 - 'cycleway': 0 - 'elevator': 1 - 'footway': 1 - 'living_street': 1 - 'motorway': 0 - 'motorway_link': 0 - 'path': 1 - 'pedestrian': 0 - 'primary': 0 - 'primary_link': 0 - 'residential': 0 - 'secondary': 0 - 'secondary_link': 0 - 'service': 0 - 'steps': 0 - 'tertiary': 0 - 'tertiary_link': 0 - 'track': 1 - 'trunk': 0 - 'unclassified': 0 \ No newline at end of file diff --git a/fixbikenet/functions.py b/fixbikenet/functions.py index e229c83..04a9f93 100644 --- a/fixbikenet/functions.py +++ b/fixbikenet/functions.py @@ -1,8 +1,8 @@ -import yaml import networkx as nx import random import numpy as np import geopandas as gpd +from . import config def map_edges_to_bike_infrastructure(g): """ @@ -18,15 +18,11 @@ def map_edges_to_bike_infrastructure(g): g : networkx.MultiDiGraph simplified graph representing the street network, with added binary edge attribute "pbi" """ - # first step: map all highway attributes - protected_bike_infra = yaml.load( - open("fixbikenet/config/config_osm.yml"), - Loader=yaml.FullLoader)["protected_bike_infra"] # add binary edge attribute "pbi" (protected bike infra: True/False) for edge in g.edges(keys=True): try: - g.edges[edge]["pbi"] = protected_bike_infra[ + g.edges[edge]["pbi"] = config.protected_bike_infra[ g.edges[edge]["highway"] ] except: