Skip to content

Conversation

@metzm
Copy link
Contributor

@metzm metzm commented Jun 30, 2023

With the parallelization of various raster modules, a memory option for a new output buffer was introduced. The calculation of the number of buffered rows did not take into account that a potentially large amount of RAM is already used for input data. This PR adjusts the calculation of the number of rows to be buffered for output maps for the modules r.neighbors, r.patch, r.resamp.filter, and r.series, avoiding accidental OOM errors. These modules should now use not (much) more than the user-specified amount of RAM.

@metzm metzm added bug Something isn't working raster Related to raster data processing C Related code is in C backport to 8.3 labels Jun 30, 2023
@metzm metzm added this to the 8.3.1 milestone Jun 30, 2023
@metzm metzm requested a review from nilason June 30, 2023 12:35
@metzm metzm modified the milestones: 8.3.1, 8.4.0 Jun 30, 2023
@metzm metzm requested a review from petrasovaa June 30, 2023 13:10
Copy link
Contributor

@nilason nilason left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

@metzm metzm merged commit 64b1955 into OSGeo:main Sep 3, 2023
metzm added a commit that referenced this pull request Sep 3, 2023
* parallelized raster modules: fix buffer sizes

* safety check for unsigned integer subtraction
@metzm metzm deleted the openmp_buffered_rows branch September 3, 2023 09:38
@neteler neteler modified the milestones: 8.4.0, 8.3.1 Oct 24, 2023
landam pushed a commit to landam/grass that referenced this pull request Oct 25, 2023
* parallelized raster modules: fix buffer sizes

* safety check for unsigned integer subtraction
neteler pushed a commit to nilason/grass that referenced this pull request Nov 7, 2023
* parallelized raster modules: fix buffer sizes

* safety check for unsigned integer subtraction
@neteler neteler changed the title parallelized raster modules: fix buffer sizes modules: fix parallelized raster modules for buffer sizes Jun 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working C Related code is in C raster Related to raster data processing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants