<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<p>Did someone have the same issue to process Sentinel 5p to tiff file with gdal as well?</p>
<pre class="moz-quote-pre" wrap="">** The overlapping image on QGIS looks like below https://imgur.com/uu6pS5n

** The two extracted tiff files can be found from
https://drive.google.com/drive/folders/1lOXyJXhhzmfs5e_WTsKPOj96CHEEIyhP?usp=sharing
</pre>
<p>Best,</p>
<br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Pham Huu, Bang<br>
<b>Sent:</b> Monday, November 8, 2021 07:09<br>
<b>To:</b> gdal-dev@lists.osgeo.org <gdal-dev@lists.osgeo.org><br>
<b>Subject:</b> Process Sentinel-5p netCDF to tiff files but overlapping appears clearly between 2 files?</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">Hello,<br>
<br>
I've used 2 Sentinel-5p scenes in hdf5 / netCDF to geoTiff by gdal<br>
version 2.2.4 like example below:<br>
<br>
First, I extract the lat and lon coordinates from one HDF5 file<br>
<br>
     gdal_translate -of VRT<br>
HDF5:"S5P_OFFL_L2__AER_AI_20210501T110005_20210501T124135_18388_01_010400_20210503T005051.nc"://PRODUCT/latitude<br>
lat.vrt<br>
     gdal_translate -of VRT<br>
HDF5:"S5P_OFFL_L2__AER_AI_20210501T110005_20210501T124135_18388_01_010400_20210503T005051.nc"://PRODUCT/longitude<br>
lon.vrt<br>
<br>
Then, I create the product.vrt like below<br>
<br>
        <VRTDataset rasterXSize="450" rasterYSize="3735"><br>
      <Metadata domain="GEOLOCATION"><br>
        <MDI key="LINE_OFFSET">0</MDI><br>
        <MDI key="LINE_STEP">1</MDI><br>
        <MDI key="PIXEL_OFFSET">0</MDI><br>
        <MDI key="PIXEL_STEP">1</MDI><br>
        <MDI key="X_BAND">1</MDI><br>
        <MDI<br>
key="X_DATASET">/home/PROJECTS/Sentinel-5P/test_L2_AER_AI/lon.vrt</MDI><br>
        <MDI key="Y_BAND">1</MDI><br>
        <MDI<br>
key="Y_DATASET">/home/PROJECTS/Sentinel-5P/test_L2_AER_AI/lat.vrt</MDI><br>
      </Metadata><br>
      <VRTRasterBand dataType="Float32" band="1"><br>
        <Metadata><br>
          <MDI key="STATISTICS_MAXIMUM">9.9692099683869e+36</MDI><br>
          <MDI key="STATISTICS_MEAN">7.78603750784e+35</MDI><br>
          <MDI key="STATISTICS_MINIMUM">-7.209698677063</MDI><br>
          <MDI key="STATISTICS_STDDEV">2.6750402750247e+36</MDI><br>
        </Metadata><br>
        <SimpleSource><br>
          <SourceFilename<br>
relativeToVRT="1">HDF5:S5P_OFFL_L2__AER_AI_20210501T110005_20210501T124135_18388_01_010400_20210503T005051.nc://PRODUCT/aerosol_index_340_380</SourceFilename><br>
          <SourceBand>1</SourceBand><br>
          <SourceProperties RasterXSize="450" RasterYSize="3735"<br>
DataType="Float32" BlockXSize="225" BlockYSize="1868" /><br>
          <SrcRect xOff="0" yOff="0" xSize="450" ySize="3735" /><br>
          <DstRect xOff="0" yOff="0" xSize="450" ySize="3735" /><br>
        </SimpleSource><br>
      </VRTRasterBand><br>
    </VRTDataset><br>
<br>
And finally, I extract the data inside the HDF5 to geoTiff and project<br>
it to EPSG:4326 CRS.<br>
<br>
    gdalwarp -geoloc -t_srs EPSG:4326 -srcnodata 9.96921e+36f<br>
product.vrt aerosol_index_340_380.tiff -tr 0.069 0.069 -tap -of GTiff<br>
<br>
I did that for 2 files which are neighbor to extract the wanted<br>
sub_dataset to tiff files and then opened them on QGIS.<br>
<br>
** The image looks like below <a href="https://imgur.com/uu6pS5n">https://imgur.com/uu6pS5n</a><br>
<br>
** The two extracted tiff files can be found from<br>
<a href="https://drive.google.com/drive/folders/1lOXyJXhhzmfs5e_WTsKPOj96CHEEIyhP?usp=sharing">https://drive.google.com/drive/folders/1lOXyJXhhzmfs5e_WTsKPOj96CHEEIyhP?usp=sharing</a><br>
<br>
I wonder, why there are clear borders (the line in the middle) between<br>
the 2 overlapping files?<br>
<br>
Thanks,<br>
<br>
</div>
</span></font></div>
</body>
</html>