-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: Interpolate one array, "re-use" weights on other arrays #363
Comments
Yes, it's possible, see the |
Wow, that's amazing. I'll take a look at it in the coming days, and if I'm able to get it working I'll try to create a small example that could be used in the documentation. |
So I tried playing around with the *: At least until you give it an index |
Try Interpolations.jl/src/b-splines/indexing.jl Lines 5 to 9 in 44ad9a6
|
Bounds checking happens before |
See #365. The preview of the new devdocs should help a lot. Good luck! |
Hi, did you get anywhere with this? I need to solve (almost) exactly the same problem as the one illustrated in the first comment. |
No, I never made any progress (see #484 ) |
This feature would be awesome for weather and climate data. For example, I often have thousands of arrays that needs to be interpoolated on a new grid and the source and destination grid is static. |
I'll have some time in about a month to think about this a bit more. There's probably a way to hack thisnow, but a stable interface to do this would be better. |
In my code I need to interpolate many different arrays at the same points. A signficant part of my computation time is spent on interpolating, but I can cut the time down significantly if it would be possible to "reuse" interpolation weights and positions. The following example illustrates.
something not to different from this:
Now, the point is that since all of the interpolations are evaluated at the same values
(x,y)
and are "defined" on the same grids, we don't really need to do all the calculations to findval2, val3
, since we can reuse the weights that were used in findingval1
.Then the question becomes:
1.1 Is it possible to make interpolations.jl export the weights and closest grid points so that I can manually perfrom the interpolations from
val2,val3
?1.2 Is there a way to tell interpolations to just interpolate three objects at the same time?
The text was updated successfully, but these errors were encountered: