Repository navigation
Generate the raster processing functions from the catalog - #504
Merged
estebanzimanyi merged 1 commit intoOct 26, 2026
Merged
Conversation
The generator retires meos_raster_base_transf, so the calls the catalog places register transform, transformPipeline, rescale, slope, tpi, tri, reclass, mapAlgebra and clip in the forms their trailing defaults allow.
shape_sig_call binds an argument declared DEFAULT NULL whose wrapper passes a NULL pointer for a NULL argument to nullptr, and a NULL row skips its decoding, as Raster_map_algebra passes NULL for a NULL customextent or pixeltype. It reads a geometry argument in the SRID of the one raster the call reads before it (SIG_SRID_OF), as the geo shapes read a geometry in the SRID of the temporal value, the CRS of a typed GEOMETRY('EPSG:n') read at no geometry argument, and a length the signature binds takes its literal with its array: clip(rast, geom) binds bands NULL and nbands 0.
RETIRE_UNCOVERED_OK names the four functions of the group the generator does not reach: dumpAsPolygons, pixelAsPoints and dumpValues, whose rows of GeomVal, of Pixel and of values with nodata flags no shape returns, and setValues, whose two-dimensional array gives the width and height of the block, C parameters no SQL argument of its signature fills.
Witness: on the branch this one stacks on, duckdb_functions() lists no clip, mapAlgebra, transform, rescale, slope, tpi, tri or reclass over raster. Here clip(r, 'POLYGON((0 1,2 1,2 3,0 3,0 1))'::GEOMETRY) over the depth raster test/sql/raster.test reads answers the 2x2 raster of pixels 10, 20, 40, 50 MobilityDB's raster regression test answers, the triangle POLYGON((0 3,1.8 3,0 1.2,0 3)) keeps pixel 10 by centre and 10, 20, 40 by touch as it answers them, and mapAlgebra(r, 1, 'SUM', '64BF', 'CUSTOM', makeEmptyRaster(2, 2, 1.0, 3.0, 1.0, -1.0, 0.0, 0.0, 3857), 1, 1) its sums 190, 280, 235, 325.
Measured over the catalog of MobilityDB master 78673b2106, whose headers are those of the pinned f89cf61f1b (the commits between them change the manual only): the generator registers 46 functions more than the branch it stacks on, none removed: clip 3, mapAlgebra 6, reclass 2, rescale 3, slope 11, tpi 3, transform 8, transformPipeline 7, tri 3. No hand registration names any of them.
estebanzimanyi
force-pushed
the
gen/raster-base-transf
branch
from
October 26, 2026 08:28
05291b4 to
67367fe
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The generator retires meos_raster_base_transf, so the calls the catalog places register transform, transformPipeline, rescale, slope, tpi, tri, reclass, mapAlgebra and clip in the forms their trailing defaults allow.
shape_sig_call binds an argument declared DEFAULT NULL whose wrapper passes a NULL pointer for a NULL argument to nullptr, and a NULL row skips its decoding, as Raster_map_algebra passes NULL for a NULL customextent or pixeltype. It reads a geometry argument in the SRID of the one raster the call reads before it (SIG_SRID_OF), as the geo shapes read a geometry in the SRID of the temporal value, the CRS of a typed GEOMETRY('EPSG:n') read at no geometry argument, and a length the signature binds takes its literal with its array: clip(rast, geom) binds bands NULL and nbands 0.
RETIRE_UNCOVERED_OK names the four functions of the group the generator does not reach: dumpAsPolygons, pixelAsPoints and dumpValues, whose rows of GeomVal, of Pixel and of values with nodata flags no shape returns, and setValues, whose two-dimensional array gives the width and height of the block, C parameters no SQL argument of its signature fills.
Witness: on the branch this one stacks on, duckdb_functions() lists no clip, mapAlgebra, transform, rescale, slope, tpi, tri or reclass over raster. Here clip(r, 'POLYGON((0 1,2 1,2 3,0 3,0 1))'::GEOMETRY) over the depth raster test/sql/raster.test reads answers the 2x2 raster of pixels 10, 20, 40, 50 MobilityDB's raster regression test answers, the triangle POLYGON((0 3,1.8 3,0 1.2,0 3)) keeps pixel 10 by centre and 10, 20, 40 by touch as it answers them, and mapAlgebra(r, 1, 'SUM', '64BF', 'CUSTOM', makeEmptyRaster(2, 2, 1.0, 3.0, 1.0, -1.0, 0.0, 0.0, 3857), 1, 1) its sums 190, 280, 235, 325.
Measured over the catalog of MobilityDB master 78673b2106, whose headers are those of the pinned f89cf61f1b (the commits between them change the manual only): the generator registers 46 functions more than the branch it stacks on, none removed: clip 3, mapAlgebra 6, reclass 2, rescale 3, slope 11, tpi 3, transform 8, transformPipeline 7, tri 3. No hand registration names any of them.