Better handling of "cube math" like `cube1 / cube2`
メンテナーはふだん 1 日以内に返信
@soxofaan がすでに取り組んでいます。
2025年3月10日 から。
評価
この issue はまだ評価されていません。
説明
The python client has since long a compelling "band math" feature, e.g.:
red = s2cube.band("B04")
nir = s2cube.band("B08")
ndvi = (nir - red) / (nir + red)
which is translated to a reduce_dimension along band dimension with the appropriate reducer.
User however also naively try to use these kind of math expressions without using the .band() method, e.g.:
cube3 = cube1 / cube2
Which kind of works: it will produce a merge_cubes operation with an overlap resolver set to "divide" in this case.
As discussed in https://github.com/Open-EO/openeo-processes/issues/280 this is unfortunately a dangerous approach because it will give unexpected results in situations without 100% overlap
Alternative approach: use merge_cubes without overlap resolver to "stack" bands of both cubes in a single cube and do apply_dimension to combine the bands as desired to a new cube. This would involve quite a bit more steps, but will result in more correct calculation:
- before merge: rename bands to ensure 0 overlap. Also: if there are no bands yet: make sure there are
merge_cubesexplicitly without overlap resolver to make sure bands are stacked- use
apply_dimension(or maybereduce_dimensionin some cases) to implement the desired operation - remame bands again to what the user expects
Quite vital to get this working is that band name handling is correct and in line with how it works backend-side. This might be a bit challenging with load_stac use cases where band detection can be a bit fuzzy.
other related issues:
- 主要言語
- Python
- スター
- 219
- フォーク
- 56
- 平均マージ
- 2日 21時間
- マージ済み PR(30日)
- 9
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Open-EO/openeo-python-client のほかの issue
-
JupyterLite supportオープンauth feature request
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
Open-EO/openeo-python-client#953 ·
メンテナーはふだん 1 日以内に返信
-
collect feedback
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
Open-EO/openeo-python-client#952 · コメント 7 件 ·
メンテナーはふだん 1 日以内に返信
-
Further decouple CubeMetadata from CollectionMetadata, and properly apply spatio-temporal filtering対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
Open-EO/openeo-python-client#949 · コメント 3 件 ·
メンテナーはふだん 1 日以内に返信
-
asset download: support file:local_path to determine target file name対応中かも @soxofaan が 46 日前に担当しました。 オープンfeature request
Open-EO/openeo-python-client#902 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
Add split_points functionality対応中かも @HansVRP が 1 日前に担当しました。 オープンjob manager
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
Open-EO/openeo-python-client#899 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
Open-EO/openeo-python-client の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 70/100
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
topoteretes/cognee#5773 ·
メンテナーはふだん 1 日以内に返信
-
MiKTeX: a failed build reports no errors because texify --quiet switches the log to file:line: styleオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
SublimeText/LaTeXTools#1718 ·