diff --git a/CHANGELOG.md b/CHANGELOG.md index ab2c010c..77ba8a90 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,9 @@ The following table shows which versions of MapReader are compatible with which _Add new changes here_ +### Fixed +- Fixes the `explore_predictions` and `explore_search_results` methods in the `DeepSoloRunner` and `MapTextRunner` classes ([#544](https://github.com/maps-as-data/MapReader/pull/544)) + ## [v1.6.2](https://github.com/Living-with-machines/MapReader/releases/tag/v1.6.2) (2025-01-02) ### Added diff --git a/mapreader/spot_text/runner_base.py b/mapreader/spot_text/runner_base.py index 3221a3df..cbc91dc7 100644 --- a/mapreader/spot_text/runner_base.py +++ b/mapreader/spot_text/runner_base.py @@ -672,6 +672,9 @@ def explore_predictions( tiles = xyz.providers.OpenStreetMap.Mapnik preds_df = self._dict_to_dataframe(self.geo_predictions) + preds_df.drop( + columns=["pixel_geometry"], inplace=True + ) # drop pixel_geometry since we can't have two polygon columns return preds_df[preds_df["image_id"] == parent_id].explore( tiles=tiles, @@ -1059,6 +1062,9 @@ def explore_search_results( geo_search_results = self._get_geo_search_results() geo_df = self._dict_to_dataframe(geo_search_results) + geo_df.drop( + columns=["pixel_geometry"], inplace=True + ) # drop pixel_geometry since we can't have two polygon columns return geo_df[geo_df["image_id"] == parent_id].explore( tiles=tiles,