Author Topic: Processing M3 L2 data  (Read 3029 times)


  • Horus (New Member)
  • *
  • Posts: 2
Processing M3 L2 data
« on: November 05, 2014, 06:35:59 AM »
I would like to use ISIS to map-project Chandrayaan M3 L2 (spectral reflectance) products, but it appears that it is not possible to import these IMGs into ISIS. The documentation of Chan1m32isis states that it is for Level 1B or 0 products only, and it does not recognize the PDS label if I try running it on a L2 .lbl file.

Am I missing something here? Or, if it isn't possible to map-project L2 products, how do other users convert M3 products into something you can work with in GIS software? Do you use the 1B products and do the conversion to spectral reflectance yourself, then use cam2map?


  • Osiris (Active Member)
  • **
  • Posts: 5
Re: Processing M3 L2 data
« Reply #1 on: January 05, 2016, 10:23:24 AM »
Same question: chan1m32isis only works on L0 or L1B.  Is there a way to ingest a PDS "RFL.IMG" file into ISIS?  thanks, Dave


  • GIS Support Team
  • Isis (Extreme Power Member)
  • *****
  • Posts: 1217
    • Email
Re: Processing M3 L2 data
« Reply #2 on: January 06, 2016, 09:52:54 AM »
What appears next, I will forever decline that I wrote it. While it might just work there are many (many) things that could go wrong. This is not a valid (or properly tested) method. Buyer beware.

One more caveat: Even proper ISIS3 support of Chandrayaan-1 M3 data is still fairly new and not all aspects have been well tested. Also USGS in collaboration with the original M3 Team is working an updated version for the positioning of the M3 data. This is still probably a year from release thus current methods will use original predict pointing (LOC files) to position the data (which have known issues).

Anyway, to get back to this story. It just so happens that the M3 reflectance file (*.img) is the same size (lines, samples, bands, bit type) as the M3 L1B PDS data product. Thus if you point the L1B label (lbl) at the reflectance (*.img) file, you can load it in. Once the L2 reflectance data is loaded, this means ALL the metadata in the ISIS cube label will be wrong (title, product, unit labels) since it thinks it loaded the L1B data. Doing a quick test it does appear the actually reflectance pixel values are untouched from the original L2 PDS file. This means you can now run "spiceinit" on the faked L1B file and "cam2map" to map project the L2 data.

steps I took to test.

(1) given all files for an L1B product (say M3G20090811T012112)
**download all related files (LOC, OBS, TIM and labels). e.g.

(2) now download the same L2 products

(3) edit the file M3G20090811T012112_V03_L1B.LBL and replace the L1B img with the L2 img
OBJECT          = RDN_FILE                                                   
  ^RDN_IMAGE    = "M3G20090811T012112_V03_RDN.IMG"                           


OBJECT          = RDN_FILE                                                   
  ^RDN_IMAGE    = "M3G20090811T012112_V01_RFL.IMG"                           

(4) run chan1m32isis , e.g.
> chan1m32isis from=M3G20090811T012112_V03_L1B.LBL loc=M3G20090811T012112_V03_LOC.IMG obs=M3G20090811T012112_V03_OBS.IMG to=M3G20090811T012112_V01_L2_HACK.cub

(5) run spiceinit
> spiceinit from=M3G20090811T012112_V01_L2_HACK.cub

(6) make a maptemplate file -
Code: [Select]
Group = Mapping
  ProjectionName     = SimpleCylindrical
  CenterLongitude    = 0.0
  LongitudeDomain    = 180
(7) run cam2map, e.g.
> cam2map from=M3G20090811T012112_V01_L2_HACK.cub to=M3G20090811T012112_V01_L2_HACK_simp0.cub

( 8 ) export to Geotiff (so that most of the incorrect metadata in the label is gone. Yes in this case this is a good thing).
> gdal_translate M3G20090811T012112_V01_L2_HACK_simp0.cub M3G20090811T012112_V01_L2_HACK_simp0.tif

Did this work...? It appears so. Is it correct - I'm not sure... see jpeg:
Note that band 1 and band 2 in the L2 image I tested appear to be just NoData.

The real fix -- obviously L2 support needs to be added to ISIS3 (which appears to be a relatively minor update), but currently I don't think this task is on anyone's radar.


This message will self-destruct in 5 minutes.
« Last Edit: January 06, 2016, 10:03:53 AM by thare »