-
Notifications
You must be signed in to change notification settings - Fork 42
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
Way forward for co-registration module #435
Comments
To clarify on the
Is that something we can do currently @erikmannerfelt? |
Wow, I'm a bit overwhelmed with the list of things left to do to have any useful feedback for the moment.
What was your idea regarding this project. Did you want to work on it in the coming days/weeks? |
Yes it is a bit overwhelming like this haha, but thankfully some of these points are fairly small! 🙂 We'll need more detailed lists, but I think those can live within each PR that will address a new step/feature listed above. The architecture work will have to be one big PR, as everything is inter-dependent on the structure. With all the discussions and the work already done in #158 trying to make the structure generic and robust, I have a clear vision of the technical steps to go through to reach every point. And I don't want to wait too long and lose it! I'd be happy to write a more detailed plan, discuss it, and combine efforts if you both can block some days for it, but can otherwise push on my own in the frame of the coreg study! 😉 My idea was to start on this full time end-of-September (for the co-registration study to reach a good stage before AGU). |
One year later, and we've addressed most of the points of this (long) issue and the core coregistration module is now close to being finalized! 🥳 🎈 Now that the structure, input support and modular arguments are fully consistent across all coregistration methods, we can more easily address the three remaining aspects (which are either about maintenance or adding new features):
Another point that comes to mind would be to add |
We currently have 25 issues open on co-registration 🙀, and a lot of notes and plans for the way forward dispersed everywhere. I initially tried to organize this in a project: https://github.com/orgs/GlacioHack/projects/3/views/2, but I think that the level of detail of the issues is too inconsistent for this, so I'm writing this summary instead!
Architecture:
We already did a lot in #158 and #329 to re-organize the coding structure to be more consistent and robust, but some points are left:
coreg.py
#327 especially about cleaning + having consistent subfunctions of class methods + side-features (see next point),fit
andapply
, and call methods depending on Point-Point, Point-Raster or Raster-Raster support, which would also completely solve Allow point clouds forCoreg
#134.Features:
We've been needing for a while to have consistent:
coreg.py
#327),coreg.py
#327),random_state
argument toCoreg
class forsubsample
cases #243, Allow custom subsampling for eachCoregPipeline
step separately. #137 and mainly the long discussion in Argumentsubsample
does not work for aCoregPipeline
#428.Most of them are not too far since we introduced a consistent structure for optimizers or binning in #158. It makes weights almost directly supported (but we'll need to raise proper warnings for methods that currently ignore, such as ICP), and will make plotting more easy by consistently treating the type of methods (binning, fit, or both) and the dimensionality of the variables (1D, 2D, ND), which can be re-used for
Tilt
orNuthKaab
fits in the affine functions.Tests:
Some tests are still a bit old or slow, several related issues could be solved all at once:
pytest.fixture
to provide consistent test data across all test modules? #427,numba
during CI tests to get adequate coverage stats #358 (comment).Performance:
⚠️ We really need to think ahead for a structure that will allow memory-efficient computations using Dask:
rioxarray
, and Add Xarray accessorgu
geoutils#383 and Add Xarray accessordem
#392, so not too much to think about!Coreg.fit
, as a regression requires all samples at once, it cannot be combined from solutions of different chunks (except in a blockwise way usingBlockwiseCoreg
). So it's all about thesubsample
which is fairly easy to deal with (read subsample per chunk + return concatenated vector). There's also the computation of derivatives needed, which are also straightforward (slope using overlapping chunks, bias_vars using normal chunks), see the thoughts in Argumentsubsample
does not work for aCoregPipeline
#428 (comment). Most other methodsresiduals
,plot
can be based on the same logic as they usesubsample
.Coreg.apply
, which might not be trivial. For bias corrections, the solution from the optimized function is applicable independently to every pixel given theirbias_vars
(coordinates, angle, etc), so very easy to apply to chunk. However, for affine methods, applying a 3D affine matrix in 4x4 format lazily to independent chunks won't work directly... it would also require a definition of the rotation center of the matrix, and maybe other things... Any thoughts on how to address this @erikmannerfelt? Or maybe @friedrichknuth has some insights?CoregPipeline.apply()
and.fit()
performance by merging matrices #79,Coreg
pre-processing for performance #437.Bugs:
Here there's a lot, but they might solve themselves (or become irrelevant) after changing architecture + tests:
#423, #422, #404, #326, #232, #193
Idea of plan moving forward:
subsample
does not work for aCoregPipeline
#428 (comment). I think we can use the structure proposed there which should work eventually 🤞! Forapply
, this should be adaptable down the line...BiasCorr
classes and rename previouscoreg.BiasCorr
incoreg.VerticalShift
#158 and Re-organize coreg.py #329.Any thoughts @adehecq @erikmannerfelt? 😄
The text was updated successfully, but these errors were encountered: