Closed remote-gianni closed 6 months ago
Hi! Could you provide some more information how you called AROSICS and which step exactly crops your result? Is it the call of the COREG_LOCAL.correct_shifts
method that crops it?
Hi Daniel
Thanks for your quick reply.
Yes, I'm using COREG_LOCAL. Pointing out the correct_shifts() method already resolved my "issue"; the 'cliptoextent' argument was set to True in my code as attached below. Setting it back to its actual default value results in AROSICS shifting the entire image as expected.
Thanks a lot!
from arosics import COREG_LOCAL
# avoid error messages if reference does not cover entire image
import numpy as np
np.seterr(divide="ignore", invalid="ignore")
reference = some image
reference_footprint = some concave hull
target = some other image
target_footprint = some other concave hull
out_path = some output path for the co-registered image
out_points = some output path for the tie-point grid
kwargs = {
"grid_res": 50,
"window_size": (64, 64),
"path_out": out_path,
"fmt_out": "ENVI",
"out_crea_options": None,
"q": False,
"nodata": (0, 0),
"calc_corners": False,
"ignore_errors": True,
"footprint_poly_ref": reference_footprint,
"footprint_poly_tgt": target_footprint,
"max_shift": 5,
"tieP_filter_level": 2,
}
CRL = COREG_LOCAL(reference, target, **kwargs)
CRL.correct_shifts(cliptoextent=True)
CRL.CoRegPoints_table.to_csv(out_points, index=False)
Description
I'm using AROSICS to perform local co-registration for several airborne flightlines. For images with lines of missing data, not the entire flightlines get co-registered.
Unlike issue #23, the tie-points are actually computed, but the returned result gets cropped.
Is there a way to avoid AROSICS using py_tools_ds' fill_holes_within_poly() cropping the output?
What I Did
The image footprint:![footprint](https://github.com/GFZ/arosics/assets/91260650/2460f367-43e6-4cc4-bee1-67acec59ea38)
The concave hull passed to AROSICS:![footprint_passed](https://github.com/GFZ/arosics/assets/91260650/729e013e-3370-4c03-b3dd-75140008ad31)
The computed tie-points (graduated by absolute shift):![tie_points](https://github.com/GFZ/arosics/assets/91260650/6cf0bbb6-99ab-436e-b336-9f1d69cff3f2)
The returned result (darkened):![result](https://github.com/GFZ/arosics/assets/91260650/7543c05d-1a92-4624-9b7c-490dc5a541b5)
The warning message: