title: Reproject and mosaic MODIS level2 using gdal/python
body: <p>I have a dataset of MODIS atmospheric products (MOD04) in .hdf format and I want to reproject and save them as Geotiff. I know that it is possible to do it using gdalwarp, but the problem is that I need to do some manipulation before saving the images. Basically, what I need is to read different subdatasets from hdf file, do some modifications using numpy, and finally save the array as a Geotiff file.</p>
  
  <p>I am not expert in using gdal, but I know generally how it works. I must note that when I open MOD04 hdf file by gdal, it seems that gdal is not able to read its GeoProjection and GeoTransform data!</p>
  
  <pre><code>&gt;&gt;&gt; src = 'D:/Test/MYD04_L2.A2007231.0745.006.2014054160056.hdf'
  &gt;&gt;&gt; dataset = gdal.Open(src,gdal.GA_ReadOnly)
  &gt;&gt;&gt; print dataset.GetProjection()
  
  &gt;&gt;&gt; print dataset.GetGeoTransform()
  (0.0, 1.0, 0.0, 0.0, 0.0, 1.0)
  </code></pre>
  
  <p>Above is an example of reading my hdf file. It is the same when I directly open the subdatasets. I am wondering if anyone knows how can I solve this?</p>