[FWTools] MODIS processing

Frank Warmerdam warmerdam at pobox.com
Wed Jan 4 10:05:04 EST 2006


On 1/4/06, Ned Horning <nedh at lightlink.com> wrote:
>
>
>
> Greetings,
>
>
>
> I have some MODIS cloud images (MOD35 – a MODIS level 2 product) that I
> would like to project into UTM and then do a binary AND to extract the
> second and third bit and then save to GeoTIFF. I need to batch process a few
> hundred images so I was thinking this would be a good project to learn to
> write a python scrip in OpenEV_FW to reap some benefits from OpenEV and
> GDAL. Has anyone out there done this sort of processing?
>
> From what I can tell gdalwarp needs an input projection but the MODIS level
> 2 products are georeferenced not projected (as far as I can tell) and I'm
> not sure how to deal with this. I see that GDAL can apply the geolocation
> information to the MODIS image when it is opened (It works in OpenEV_FW
> although the GDAL documentation does not explicitly mention that
> georeferencing is supported for HDF MODIS level 2 imagery) but I would like
> to know how to project the georeferenced MODIS image if this is possible.

Ned,

Does the MODIS HDF image appear to have GCPs?  I
would imagine that is what OpenEV is using for geolocation.
If so, you can use gdalwarp to rectify the image to UTM.

eg.

gdalwarp -t_srs '+proj=utm +zone=11 +datum=WGS84' infile outfile

You might want to use the -order argument to limit the polynomial
order to 2, if you find problems with it.  You can check the GCPs
with gdalinfo.

Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent



More information about the FWTools mailing list