miscalculation in `Interpolator._extrapolate_rows`
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Accessibilité débutants
- 35/100
Piste de recherche
Commencez dans geotiepoints/init.py, au niveau de l'appel de modis5kmto1km à fill_borders, puis examinez Interpolator._extrapolate_rows et la manière dont row_indices est construit. Reproduisez l'entrée signalée de 406 x 271 et vérifiez les dimensions et les indices de tie-data obtenus ; le travail est terminé lorsque le comportement de l'extrapolation des bordures est vérifié et corrigé ou clairement expliqué, et que l'option bbox de RectBivariateSpline a été évaluée.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
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
- Langage dominant
- Python
- Étoiles
- 30
- Forks
- 18
- Merge moyen
- 5 j 9 h
- PR mergées (30 j)
- 1
Préparer son environnement
- Aucun Dockerfile ni fichier Docker Compose
- Propose un modèle de pull request
- Aucun guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de pytroll/python-geotiepoints
-
Add link to VII documentation.Ouverte
Difficulté 1/5 Moins d'une heure Accessibilité débutants 15/100
pytroll/python-geotiepoints#25 · 3 commentaires ·
-
Difficulté 4/5 3-5 jours Accessibilité débutants 35/100
pytroll/python-geotiepoints#24 · 1 commentaire ·
-
5-dimensional interpolationOuvertequestion
Difficulté 2/5 Une demi-journée Accessibilité débutants 52/100
pytroll/python-geotiepoints#20 · 3 commentaires ·
Toutes les issues de pytroll/python-geotiepoints
Issues similaires
-
curriculum documentation quality
Difficulté 2/5 1-3 heures Accessibilité débutants 77/100
githubnext/gh-aw-workshop#5367 ·
Les mainteneurs répondent en général sous 3 jours
-
Create Noise Latents ignores randomize_seed and produces the same noise every runPeut-être pris @griptapeops l’a pris aujourd’hui. Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
griptape-ai/griptape-nodes-library-diffusers#127 ·
Les mainteneurs répondent en général sous 1 jour
-
Jenkins capacity report: metrics history is lost when archiving a month failsPeut-être pris @RaphaelFakhri l’a pris aujourd’hui. Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
adoptium/infrastructure#4568 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
huggingface/deep-rl-class#723 ·
-
premises-missing
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
WingedGuardian/GENesis-AGI#3928 ·
Les mainteneurs répondent en général sous 1 jour