<div dir="ltr">Etienne,<div><br></div><div>This workaround seems to have solved my problem, although I needed to increase the value from 1000 to 2000 in some instances (some of the GRIB2 messages worked with 1000, others didn't).</div>
<div><br></div><div>So I am now using:</div><div><br></div><div> <span style="font-size:13px;font-family:arial,sans-serif">gdalwarp -wm 2000 --config GDAL_CACHEMAX 2000 -of netcdf -srcnodata 9999.0 -dstnodata 9999.0 -t_srs EPSG:4326 conus-wspd-01.bin </span><a href="http://conus-wspd-01.nc">conus-wspd-01.nc</a></div>
<div><br></div><div>Thanks very much - I will update the trac ticket.</div><div><br></div><div>Jason</div><div><br></div><div class="gmail_extra"><div><div dir="ltr"><div><div><div><a href="mailto:Jason.Greenlaw@noaa.gov" target="_blank"></a></div>
<div><br></div></div></div></div></div>
<br><br><div class="gmail_quote">On Wed, Jul 17, 2013 at 6:49 PM, Etienne Tourigny <span dir="ltr"><<a href="mailto:etourigny.dev@gmail.com" target="_blank">etourigny.dev@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
You probably are experiencing a known bug, when the warping operation needs more memory than the warp cache. <div><br></div><div>Try setting adding the following to the gdalwarp command (if it doesn't work try a larger value).<div>
<br></div><div>--config GDAL_CACHEMAX 1000 -wm 1000<div><br></div><div>Also please update the ticket with any new information</div><div><br></div><div><a href="http://trac.osgeo.org/gdal/ticket/4484" target="_blank">http://trac.osgeo.org/gdal/ticket/4484</a><br>
<br>cheers</div><span class=""><font color="#888888"><div>Etienne</div></font></span><div><br><div class="gmail_quote"><div class="im">On Wed, Jul 17, 2013 at 5:31 PM, Jason Greenlaw - NOAA Affiliate <span dir="ltr"><<a href="mailto:jason.greenlaw@noaa.gov" target="_blank">jason.greenlaw@noaa.gov</a>></span> wrote:<br>
</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div class="h5"><div dir="ltr">I am experiencing strange behavior when reprojecting/converting a GRIB2 file to NetCDF using gdalwarp, where the resulting NetCDF file is missing lots of data (or possibly being set incorrectly to NoData) west of a certain longitude. However, if I instead reproject from GRIB2 to an intermediate format (e.g. GeoTIFF), then convert to NetCDF using gdal_translate, the result is correct.<div>
<br></div><div>The source projection is the weather service's custom lambert conformal, and the destination is WGS84. I'm using the following command:</div><div><br></div><div> gdalwarp -wm 256 -of netcdf -srcnodata 9999.0 -dstnodata 9999.0 -t_srs EPSG:4326 conus-wspd-01.bin <a href="http://conus-wspd-01.nc" target="_blank">conus-wspd-01.nc</a><br>
</div><div><br></div><div>GDAL versions tested were 1.9.2 and 1.10.</div><div><br></div><div>Screenshot of original GRIB2 file (first GRIB message) as displayed in ArcMap: <a href="http://jetstreak.unh.edu/gdal/full.png" target="_blank">http://jetstreak.unh.edu/gdal/full.png</a></div>
<div>Screenshot of resulting NetCDF file (variable Band1) as displayed in ncBrowse: <a href="http://jetstreak.unh.edu/gdal/cropped.png" target="_blank">http://jetstreak.unh.edu/gdal/cropped.png</a></div><div><br></div><div>
Original GRIB2 file (6.3mb): <a href="http://jetstreak.unh.edu/gdal/conus-wspd-01.bin" target="_blank">http://jetstreak.unh.edu/gdal/conus-wspd-01.bin</a></div>
<div>Resulting NetCDF file (171mb): <a href="http://jetstreak.unh.edu/gdal/conus-wspd-01.nc" target="_blank">http://jetstreak.unh.edu/gdal/conus-wspd-01.nc</a></div><div><br></div><div>Anyone run into a similar problem or have any ideas for how to resolve this?</div>
<div><br></div><div>Thanks,</div><div>Jason</div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div><div>
</div></div>
<br></div></div><div class="im">_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org" target="_blank">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></div></blockquote></div><br></div></div></div>
</blockquote></div><br></div></div>