miscalculation in `Interpolator._extrapolate_rows`
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 35/100
Rechercherichtung
Beginnen Sie in geotiepoints/init.py beim Aufruf von modis5kmto1km zu fill_borders und untersuchen Sie anschließend Interpolator._extrapolate_rows sowie die Erstellung von row_indices. Reproduzieren Sie die gemeldete Eingabe mit den Abmessungen 406 x 271 und prüfen Sie die resultierenden tie-data-Abmessungen und -Indizes; abgeschlossen ist die Aufgabe, wenn das Verhalten der Randextrapolation verifiziert und korrigiert oder klar erklärt wurde und die bbox-Option von RectBivariateSpline bewertet wurde.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Hello!
Somehow I was recreating something similar to your modis5kmto1km function, when I realized we were building the same thing I thought let's compare and noticed some differences, so I deconstructed the code behind to understand the differences and I believe I found a major issue into it:
In the modis5kmto1km function I noticed at line 83 (on main) what I believe is the root of the issue:
satint.fill_borders("y", "x") => here
Somehow that line increases the dimensions of your self.tie_data entries containing the x, y, z coordinnates.
A typical 406 x 271 modis latitude 2d array becomes a 812 x 273. Going from 271 to 273 make sense to allow the interpolation of border but I can't get how going from 406 to 812 can make sense.
Especially considering the fact that your self.row_indices (which reflects the increment of the axis been used later in the RectBivariateSpline function), in cahnging in such a way as if it meant one pixel was added to the top border while 405 pixels are added at the bootom of the image.
The culprit to me is the _extrapolate_rows function from your Interpolator class which receives two rows as entry and systematically returns 4 while looping over the rows.
I hope I'm wrong, please correct me if so.
Note, the RectBivariateSpline function support the bbox parameter that would strongly simplify your code by allowing the extrapolation natively.
https://docs.scipy.org/doc/scipy-1.15.0/reference/generated/scipy.interpolate.RectBivariateSpline.html
- Vorherrschende Sprache
- Python
- Sterne
- 30
- Forks
- 19
- Ø Merge
- 5 T. 9 Std.
- Gemergte PRs (30 T.)
- 1
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Kein Beitragsleitfaden
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus pytroll/python-geotiepoints
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 15/100
pytroll/python-geotiepoints#25 · 3 Kommentare ·
-
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 35/100
pytroll/python-geotiepoints#24 · 1 Kommentar ·
-
question
Schwierigkeit 2/5 Ein halber Tag Anfängerfreundlichkeit 52/100
pytroll/python-geotiepoints#20 · 3 Kommentare ·
Alle Issues in pytroll/python-geotiepoints
Ähnliche Issues
-
good first issue infrastructure
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
kuznia-rdzeni/coreblocks#1135 ·
-
good first issue server
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 85/100
Maintainer antworten meist innerhalb von 1 Tag
-
documentation priority: high
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
a-lex-s/mealie-telegram-bot#54 ·
Maintainer antworten meist innerhalb von 1 Tag
-
type/test
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
SaltedTan/virgil-language-server#218 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 83/100
btclib-org/btclib-wallet#541 ·
Maintainer antworten meist innerhalb von 1 Tag