<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<div class="" style="word-wrap:break-word; line-break:after-white-space">Hi gdal-dev, I am Takahiro, a student who is using gdal_translate.
<div class="">I have an issue with gdal_translate and would like to ask a question.</div>
<div class="">I used gdal_translate to transform a NCEP GRIB file (downloadable from <a href="https://data.eol.ucar.edu/cgi-bin/codiac/fgr_form/id=21.093" class="">https://data.eol.ucar.edu/cgi-bin/codiac/fgr_form/id=21.093</a>, or attached to this email) to
GeoTiff, and compare those 2 data formats. The command I used is</div>
<div class="">
<div class="" style="margin:0px; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo">
>gdal_translate -of GTiff st4_pr.2017092016.01h st4_pr.2017092016.01h.tif</div>
</div>
<div class=""><br class="">
</div>
<div class="">(The GRIB file I used was st4_pr.2017092016.01h, which can be downloaded from the above link by specifying “Begin Date/Time” to “20170920”/“15:00:00” and “End Date/Time” to “20170920”/“15:59:59”.)</div>
<div class=""><br class="">
</div>
<div class="">Then I read the 2 data files in R and checked if the original value at a certain grid cell in the GRIB file remained at the same grid cell in the GeoTiff file, but the value was shifted by 6 rows (the value I checked was 9.75 [mm/hour] that was
stored in index [100,86] in the original GRIB file, but it was shifted to [106,86] in the GeoTiff file).</div>
<div class=""><br class="">
</div>
<div class="">You can see the Python script used for reading the original GRIB file here: <a href="https://bpa.st/ZNOSI" class="">https://bpa.st/ZNOSI</a></div>
<div class="">The R script used for checking the tif-translated data: <a href="https://bpa.st/WZLSY" class="">https://bpa.st/WZLSY</a></div>
<div class=""><br class="">
</div>
<div class="">The version of gdal_translate I used is 3.0.2.</div>
<div class="">Is this a known issue of gdal_translate? Or is this issue not supposed to happen (is this the mistake of my side?)?</div>
<div class=""><br class="">
<div class="">
<div class="">Best regards,</div>
<div class="">Takahiro</div>
</div>
</div>
<div class="">
<div></div>
</div>
</div>
<div class="" style="word-wrap:break-word; line-break:after-white-space">
<div class="">
<div></div>
<div class=""><br class="">
</div>
<br class="x_Apple-interchange-newline">
</div>
<br class="">
</div>
</body>
</html>