Open-EO / Open-EO/openeo-python-driver

apply_polygon (previously known as chunk_polygon) abuses MultiPolygon as collection of polygons in its internal API

Open
#288 1 comment 0 reactions 1 assignee View on GitHub

@JeroenVerstraelen is already working on this.

Since Jun 17, 2024.

  • #291 by @JeroenVerstraelen — open
  • #801 by @JeroenVerstraelen — open
technical debt
Dominant language
Python
Stars
12
Forks
8
Avg merge
6d 3h
Merged PRs (30d)
4

Description

Stumbled on this while working on #287:

The apply_polygon process implementation (originally added as chunk_polygon in https://github.com/Open-EO/openeo-python-driver/commit/a411109cbf909a316bac5ea2945c20b4a27c932d) coerces the provided geometries into a MultiPolygon :

https://github.com/Open-EO/openeo-python-driver/blob/ea078ffc6679cbed3cc7b2a8466c999a12f1c1a1/openeo_driver/ProcessGraphDeserializer.py#L859-L874

and pushes this API through into geopyspark driver, e.g.
https://github.com/Open-EO/openeo-geopyspark-driver/blob/1f22c0da34535e986908480673ad341c9f89324d/openeogeotrellis/geopysparkdatacube.py#L572-L575

MultiPolygon should not be abused as a collection of polygons. Instead the API should use something like a FeatureCollection or vector cube abstraction

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.