<div dir="ltr">Thanks so much for your reply.<span class="gmail-comment-copy"> r.neighbours : <a href="https://grass.osgeo.org/grass-stable/manuals/r.neighbors.html" rel="nofollow noreferrer">grass.osgeo.org/grass-stable/manuals/r.neighbors.html</a> is probably more appropriate. Even if i notice one limit : the tool handles only raster with one band (input). No multi bands.</span>
<div class="gmail-js-comment-actions gmail-comment-actions"><div class="gmail-d-inline-flex gmail-ai-center">
</div></div>
</div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">Le mer. 3 déc. 2025 à 13:22, Richard McDonnell <<a href="mailto:richard.mcdonnell@opw.ie">richard.mcdonnell@opw.ie</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="msg432389442157252947">
<div lang="EN-IE">
<div class="m_432389442157252947WordSection1">
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)">Hi,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)">The Fill NoData tool would seem to be the tool you should look at. But you would have to use the mask to set all pixels in the shadowed
regions to NoData, then run the Fill NoData tool<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)">(Raster
</span><span style="font-size:11pt;font-family:Wingdings;color:rgb(31,73,125)">è</span><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)"> Analysis
</span><span style="font-size:11pt;font-family:Wingdings;color:rgb(31,73,125)">è</span><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)"> Fill NoData)<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)">Kind Regards,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)">Richard<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11pt;font-family:"Calibri",sans-serif;color:rgb(31,73,125)"><u></u> <u></u></span></p>
<table style="font-size:9pt;height:321px;font-family:Arial,sans-serif;width:500px;line-height:15px" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="font-size:9pt;font-family:Arial,sans-serif;width:500px;color:rgb(0,77,68);padding-bottom:6px"><span style="font-family:Arial,sans-serif;font-weight:bold;color:rgb(0,77,68)"><br>——</span><br><span style="font-family:Arial,sans-serif;font-weight:bold;color:rgb(0,77,68)">Richard McDonnell MSc GIS</span><br><span style="font-family:Arial,sans-serif;color:rgb(0,77,68)"><i>Flood Risk Management - Data Management</i></span><br><br><span style="font-family:Arial,sans-serif;color:rgb(0,77,68)">——</span><br><span style="font-family:Arial,sans-serif;font-weight:bold;color:rgb(0,77,68)">Oifig na nOibreacha Poiblí</span><br><span style="font-family:Arial,sans-serif;color:rgb(0,77,68)">Office of Public Works</span><br><br><span style="font-family:Arial,sans-serif;font-weight:bold;color:rgb(86,81,72)">Sráid Jonathan Swift, Baile Átha Troim, Co na Mí, C15 NX36
</span><br><span style="font-family:Arial,sans-serif;color:rgb(86,81,72)">Jonathan Swift Street, Trim, Co Meath, C15 NX36</span><br><span style="font-family:Arial,sans-serif;color:rgb(86,81,72)">——</span><br><span style="font-family:Arial,sans-serif;color:rgb(86,81,72)">M +353 87 688 5964 T +353 46 942 2409</span><br><a href="https://gov.ie/opw" target="_blank">https://gov.ie/opw</a><br><br><span style="font-family:Arial,sans-serif;color:rgb(0,77,68)">——<br>To send me
files larger than 30MB, please use the link below
<a href="https://filetransfer.opw.ie/filedrop/richard.mcdonnell@opw.ie" target="_blank">https://filetransfer.opw.ie/filedrop/richard.mcdonnell@opw.ie</a><br></span><br><span style="font-family:Arial,sans-serif;color:rgb(0,77,68)">Email Disclaimer:
<a href="https://www.gov.ie/en/organisation-information/439daf-email-disclaimer/" target="_blank">https://www.gov.ie/en/organisation-information/439daf-email-disclaimer/</a>
</span></td></tr></tbody></table>
<div style="border-width:medium medium medium 1.5pt;border-style:none none none solid;border-color:currentcolor currentcolor currentcolor blue;padding:0cm 0cm 0cm 4pt">
<div>
<div style="border-width:1pt medium medium;border-style:solid none none;border-color:rgb(225,225,225) currentcolor currentcolor;padding:3pt 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:11pt;font-family:"Calibri",sans-serif">From:</span></b><span lang="EN-US" style="font-size:11pt;font-family:"Calibri",sans-serif"> QGIS-User <<a href="mailto:qgis-user-bounces@lists.osgeo.org" target="_blank">qgis-user-bounces@lists.osgeo.org</a>>
<b>On Behalf Of </b>celati Laurent via QGIS-User<br>
<b>Sent:</b> 03 December 2025 10:11<br>
<b>To:</b> qgis-user <<a href="mailto:qgis-user@lists.osgeo.org" target="_blank">qgis-user@lists.osgeo.org</a>><br>
<b>Subject:</b> [Qgis-user] Set new pixel radiometric values based on neighborhood?<u></u><u></u></span></p>
</div>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Dear all, <u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">I work with Qgis (especially with processing tools allowing to use qgis, orfeotoolbox, grass, saga tools). I'm performing segmentations on infrared aerial images (3 bands : NIR, R, G).
<u></u><u></u></p>
</div>
<p class="MsoNormal" style="margin-bottom:12pt"><br>
One of the problems comes from shadow (especially from trees) which affects the segmentation results. Based on an analysis of the spectral signatures of the shadow pixels, I managed to generate a mask of these pixels.I paste below a screenshot showing the aerial
data + the aerial data with this cloud mask.<br>
<br>
The idea (which might be bad) would be to generate a new aerial data by modifying the radiometric values of the three NIR, R, and V bands of the aerial data only for these shadow pixels. I thought one approach would be to define a new radiometric value for
these pixels based on the values of neighboring pixels not affected by the shadow mask? In other words, the new radiometric values of the shadow pixels in aerial data would correspond to neighboring radiometric values (tree vegetation, agricultural plot, etc.).
This is intended to mitigate the impact of shadow pixels on subsequent segmentation a posteriori.<u></u><u></u></p>
<div>
<p class="MsoNormal">Is there a QGIS tool or another (OTB, GRASS, Saga) that would allow defining new radiometric values only for certain pixels of a multiband raster, based on neighboring radiometric values? (A kind of nearest neighborhood averaging, using
a sliding window? or other).<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Thanks so much<u></u><u></u></p>
</div>
<p class="MsoNormal" style="margin-bottom:12pt"><br>
<img width="940" height="277" style="width: 9.7916in; height: 2.8854in;" id="m_432389442157252947_x0000_i1025" src="cid:ii_19ae476264d4cff311" alt="image.png"><br>
<br>
<u></u><u></u></p>
</div>
</div>
</div>
</div>
</div></blockquote></div>