HDF-EOS V2 MODIS daily L3 1km band1 Texture Product
SCF Revision 5.0.0, Octobr 2004, by K. Didan

Product ID(s): MODAGTEX L3 daily 

Description:
        MODIS Level 3 1km Land Surface Reflectance Aggregation (SRAGG) - The L3
        SRAGG product contains surface reflectance at 1km resolution for bands
        1 - 7. Multiple observations at any 250m or 500m grid cells read from 
        L2G input files are first aggregated (only good observations are used)
        to produce a single reflectance value (for each band) for the grid by 
        computing weighted average of the observations. Observations are 
        weighted by the observation coverage. Observations from different 
        orbits are aggregated separately. All 250m or 500m observations that 
        fall into a 1km grid cell are then averaged to give the aggregated 
        reflectance value for that 1km grid.

        Depending on the number of orbits present in the input L2G, for each
        1km grid cell there will be one or more aggregated output. An aggregated
        output observation for a 1km grid cell in the output tile contains four
        angles (viewing and solar angles), seven reflectance values (bands 1-7),
        seven band qa (bands 1-7) and a 1km state QA. For each pixel a maximum 
        of four aggregateed observations (from four different orbits) are 
        output. The observation that is closest to the nadir view is stored as
        the first observation. Whenever more than one output observation is 
        present observations with diverse viewing geometry are selected for
        output.
        
        For pratical reasons, the Aggregation process will omitt all reflectances 
        below -100, emanating from the atmospheric correction process. Hence, all
        surface reflectances will be within range -100 to 16000. More over, aggregation 
        takes place only on SHALLOW_OCEAN, LAND, OCEAN_COASTLINES,
    		SHALLOW_INLAND_WATER, EPHEMERAL_WATER pixels only. 
		
			The algorithm also implements a disk saving feature, where the number of output orbits 
			will be variable and at most 4.  The number of orbits (Layers) will vary with latitude.

        
Point of Contact:
        Kamel Didan
        Terrestrial Biophysics & Remote Sensing.
        1110 E. South Campus Drive, FCR Bldg#33, Room 313
        University of Arizona, 
        Tucson, AZ 85721
       (520) 621-8514
			  kamel@ag.arizona.edu 

Principal Investigator(s):
        Chris Justice 
        Univeristy of Maryland, College Park
        NASA's Goddard Space Flight Center, Code 923
        Greenbelt, MD 20771
        (301) 286-7372
        justice@kratmos.gsfc.nasa.gov

===========================================================================

Generic Constructs

Generic Constructs

ECS Metadata Strings:

   Notes:
      1. "FR" is an abbreviation for "FREE_RANGE".
      2. "D/T" is an abbreviation for "DATE/TIME"
      3. (A) means that multiple values are stored within a single array.
      4. A value of "Variable" indicates that this value will vary
         according to the granule being processed.
      5. "M" means class M.
      6. (C) means that multiple values are stored as class members.

CoreMetadata.0
    This string will contain the following PVL fields:

                                                     #
        Field Name                        Data      of   Value
                                          Type    Values
  GROUP = INVENTORYMETADATA

    GROUP = CollectionDescriptionClass
        SHORTNAME                         STRING     1   "MODAGTEX"
        VERSIONID                         INTEGER/ST    1   variable
    END_GROUP = CollectionDescriptionClass

    GROUP = ECSDataGranule
        SIZEMBECSDATAGRANULE              DOUBLE     1   Variable
        REPROCESSINGPLANNED               STRING     1   "no further update
                                                         anticipated"
        REPROCESSINGACTUAL                STRING     1   "processed once"
        LOCALGRANULEID                    STRING     1   Variable
        DAYNIGHTFLAG                      STIRNG     1   Variable
        PRODUCTIONDATETIME                D/T        1   Variable
    END_GROUP = ECSDataGranule

    GROUP = PGEVersionClass
        PGEVERSION                        STRING     1   "2"
    END_GROUP = PGEVersionClass

    GROUP = InputGranule
        INPUTPOINTER                      STRING   FR(A) Variable
    END_GROUP = InputGranule

    GROUP = RangeDateTime
        RANGEBEGINNINGDATE                DATE       1   Variable
        RANGEBEGINNINGTIME                TIME       1   Variable
        RANGEENDINGDATE                   DATE       1   Variable
        RANGEENDINGTIME                   TIME       1   Variable
    END_GROUP = RangeDateTime

    GROUP = SpatialDomainContainer
      GROUP = HorizontalSpatialDomainContainer
        GROUP = GPolygon
          GROUP = GRing
              EXCLUSIONGRINGFLAG          STRING     1   "N"
          END_GROUP = GRing

          GROUP = GRingPoint
              GRINGPOINTLATITUDE          DOUBLE   4(A)  Variable
              GRINGPOINTLONGITUDE         DOUBLE   4(A)  Variable
              GRINGPOINTSEQUENCENO        INTEGER  4(A)  Variable
          END_GROUP = GRingPoint
        END_GROUP = GPolygon
      END_GROUP = HorizontalSpatialDomainContainer
    END_GROUP = SpatialDomainContainer

    GROUP = OrbitCalculatedSpatialDomain
        ORBITNUMBER                       INTEGER  FR(C) Variable
        EQUATORCROSSINGLONGITUDE          DOUBLE   FR(C) Variable
        EQUATORCROSSINGDATE               DATE     FR(C) Variable
        EQUATORCROSSINGTIME               TIME     FR(C) Variable
    END_GROUP = OrbitCalculatedSpatialDomain


    GROUP = MeasuredParameter
        PARAMETERNAME                     STRING     1   "Surface_Refl"

        GROUP = QAFlags
            AUTOMATICQUALITYFLAG          STRING     1    Variable
            AUTOMATICQUALITYFLAGEXPLANATION
                                          STRING     1    Variable
            OPERATIONALQUALITYFLAG        STRING     1    Variable"
            OPERATIONALQUALITYFLAGEXPLANATION
                                          STRING     1    Variable
            SCIENCEQUALITYFLAG            STRING     1    Variable
            SCIENCEQUALITYFLAGEXPLANATION
                                          STRING     1    Variable
        END_GROUP = QAFlags

        GROUP = QAStats
            QAPERCENTINTERPOLATEDDATA      INTEGER    1   Variable
            QAPERCENTMISSINGDATA           INTEGER    1   Variable
            QAPERCENTOUTOFBOUNDSDATA       INTEGER    1   Variable
        END_GROUP = QAStats
    ENDGROUP = MeasuredParameter

    GROUP = AdditionalAttributes
        ADDITIONALATTRIBUTENAME          STRING   FR(C) Variable
        PARAMETERVALUE                   STRING   FR(C) Variable

        ADDITIONALATTRIBUTENAME.1  = QAPERCENTGOODQUALITY
        ADDITIONALATTRIBUTENAME.2  = QAPERCENTOTHERQUALITY
        ADDITIONALATTRIBUTENAME.3  = QAPERCENTNOTPRODUCEDCLOUD
        ADDITIONALATTRIBUTENAME.4  = QAPERCENTNOTPRODUCEDOTHER
        ADDITIONALATTRIBUTENAME.5  = HORIZONTALTILENUMBER
        ADDITIONALATTRIBUTENAME.6  = VERTICALTILENUMBER
        ADDITIONALATTRIBUTENAME.7  = Tile_ID
        ADDITIONALATTRIBUTENAME.7  = INPUTFILESRESOLUTION

    END_GROUP = AdditionalAttributes

    GROUP = AssociatedPlatformInstrumentSensor
        ASSOCIATEDINSTRUMENTSHORTNAME              STRING     1   "MODIS"
        ASSOCIATEDPLATFORMSHORTNAME                STRING     1   "Terra"/"Aqua"
        ASSOCIATEDSENSORSHORTNAME                  STRING     1   "MODIS"
    END_GROUP = SensorCharacteristic

  ENDGROUP = INVENTORYMETADATA

ProductMetadata.0

    This string will contain the following PVL fields:

                                                     #
        Field Name                        Data      of   Value
                                          Type     Valu
                                                    es
GROUP = ARCHIVEDMETADATA

    GROUP = BoundingRectangle
        NORTHBOUNDINGCOORDINATE           DOUBLE     1   Variable
        SOUTHBOUNDINGCOORDINATE           DOUBLE     1   Variable
        EASTBOUNDINGCOORDINATE            DOUBLE     1   Variable
        WESTBOUNDINGCOORDINATE            DOUBLE     1   Variable
    END_GROUP = BoundingRectangle


    ALGORITHMPACKAGEACCEPTANCEDATE        STRING     1   "2004-10-01"
    ALGORITHMPACKAGEMATURITYCODE          STRING     1   "Normal"
    ALGORITHMPACKAGENAME                  STRING     1   "MODPRAGG"
    ALGORITHMPACKAGEVERSION               STRING     1   "5"
    GEOANYABNORMAL                        STRING     1   Variable
    GEOESTMAXRMSERROR                     DOUBLE     1   Variable
    LONGNAME                              STRING     1  "MODIS NIR 1km Texture"
    PROCESSINGCENTER                      STRING     1    "MODAPS"
    SYSTEMFILENAME                        STRING     1   Variable
    NUMBEROFGRANULES                      INTEGER    1   Variable
    GRANULEDAYNIGHTFLAG                   STRING   FR(A) Variable
    GRANULEBEGINNINGDATETIME              D/T      FR(A) Variable
    GRANULEENDINGDATETIME                 D/T      FR(A) Variable
    NUMBEROFORBITS                        INTEGER    1   Variable
    CHARACTERISTICBINANGULARSIZE          DOUBLE     1   Variable
    CHARACTERISTICBINSIZE                 DOUBLE     1   Variable
    DATACOLUMNS                           INTEGER    1   Variable
    DATAROWS                              INTEGER    1   Variable
    GLOBALGRIDCOLUMNS                     INTEGER    1   Variable
    GLOBALGRIDROWS                        INTEGER    1   Variable
    NADIRDATARESOLUTION                   STRING     1   "1km"
    REDUCEDVOLUME                  				STRING     1   "YES or NO"
    MAXIMUMNUMLAYERS                  		INTEGER    1   Variable
    MAXIMUMOBSERVATIONS                   INTEGER    1   Variable
    COVERAGECALCULATIONMETHOD             STRING     1   "area"
    SPSOPARAMETERS                        STRING     1   "2015"
    DESCRrevision                         STRING     1    Variable
    ProductionHistory                     STRING     1    Variable

ENDGROUP = ARCHIVEDMETADATA

StructuralMetadata.0
    This string will be populated automatically by HDF-EOS.

Grid Structure: MOD_Grid_Texture

    Data Fields:
                Texture_Band1, Texture_QC       

    Dimensions:

        Dimension Name                  Value
        
        YDim:MOD_Grid_Texture           "DataRows"
        XDim:MOD_Grid_Texture           "DataColumns"

    Corner Locations:

        Corner                Values

        UpperLeftPointMtrs    (Variable, Variable)

        LowerRightPointMtrs   (Variable, Variable)

    Geographic Grid Projection Parameters:

        Integrized Sinusoidal Projection
            Projection        GCTP_ISINUS
            ProjParam[0]          6371007.181
            ProjParam[1 to 7]     0.0
            ProjParam[8]          21600
            ProjParam[9]          0.0
            ProjParam[10]         1.0
            ProjParam[11 to 12]   0.0
            Spherecode            -1
            GridOrigin            HDFE_GD_UL

        Interrupted Goodes Homolosine Projection
            Projection            GCTP_GOOD
            ProjParam[0 to 12]    0.0
            Spherecode            19
            GridOrigin            HDFE_GD_UL

        Lambert Azimuthal Equal Area Projection
            Projection            GCTP_LAMAZ
            ProjParam[0]          6371228.0
            ProjParam[1 to 5]     0.0
            ProjParam[6]          Variable
            ProjParam[7 to 12]    0.0
            Spherecode            19
            GridOrigin            HDFE_GD_UL

===========================================================================

Description of SDS Data Fields
-------------------------------

Data Field_1
------------

        Data Field Name:  Texture_Band1 

        Description: Maximum texture from band1 surface reflectance 

        Type: HDF-uint16

        HDF Attributes:

                                  Number of
                                  Values or
                                    Max.
        Attribute        Data      String    Value
                         Type      Length

        long_name        STRING      24      "Daily 1km Band1 Texture" 
        units            STRING      11       reflectance 
        valid_range      INT16       2       0, 65534 
        _FillValue       INT16       1       65535 
        scale_factor     FLOAT64     1       0.0001 
        add_offset       FLOAT64     1       0.0
        scale_factor_err FLOAT64     1       0.0
        add_offset_err   FLOAT64     1       0.0
        calibrated_nt    INT32       1       5

Data Field_2
------------

        Data Field Name: Texture_QC 

        Description: Quality of band1 texture 

        Description: QC in bands 1-7  

                Bits 0-1: Modland QA bits
                  key:  00: Product produced at ideal quality
                        01: Product produced, less than ideal quality.
                        10: Product not produced due to cloud effects.
                            
           - See Notes below.
                        11: Product not produced for other reason
                Bits 2-5: Atmospheric Quality Flags
              Dead Dectector flag superceeds other cases.
              So a dead dectector flag does not exlcude cases 9,10,11, and 12.
                  key:  0000: Highest Quality
      0110: (6)  dead detector; Less than 50% data has been copied from adjacent detector
      0111: (7)  dead detector; More that 50% data has been copied from adjacent detector
      1000: (8)  dead detector; All data has been copied from adjacent detector
                  1001: (9)  solar zenith >= 85 degrees
                        1010: (10) solar zenith >= 75 and < 85 degrees
                1011: (11) missing input
                        1100: (12) Internal constants used in place of climatology
                        1101: (13) Quality so low that it is not useful
                        1110: (14) L1B data faulty
                        1111: (15) not useful for any other reason/not processed
                Bits 6-7: Geospatial Quality
                  key:  00: 25% or less of the finer resolution data contribued
                            to this 1km pixel
                        01: 50% "
                        10: 75% "
                        11: 100% "

        Type: HDF-uint8

        HDF Attributes:

                                  Number of
                                  Values or
                                    Max.
        Attribute        Data      String    Value
                         Type      Length

        long_name        STRING      28      "Quality of 1km Band1 Texture"
        units            STRING      13      class or flag 
        valid_range      INT16       2       0, 254 
        _FillValue       INT16       1       255 

NOTE: Janaury/2001 by Kamel Didan
------------------------------
  A fix wasimplemented to properly compute the TEXTURE data. Right now
	the code will compute the std-dec/mean for the band 1.  It was not doing so before!
	More filters are applied, to properly interpret MOD09 quality bits.

NOTE 1: June 12/2000 by Kamel Didan
------------------------------------
 This is a MODLAND-wide decision stemming from the fact that
  outputing "mediocre/cloudy" data is better than FILL data.
  For at least the user will find (by inspecting the data) the
  reasons why it was labeled as such.
                                

NOTE 2: July/1999 by Kamel Didan
------------------------------
  The actual "Aggregate_QC" FILL VALUE is not 65535, it is a dynamic
        FILL VALUE that is adjusted by the Land-Water mask.  To be useful for any
        comparison the user should mask the Land-Water field and then compare
        to 65535 to realize wether it is FILL or not.  This was done to convey 
        the correct Land-Water mask even when data was not present or bad.
NOTE: Deember/1999 by Kamel Didan
------------------------------
  Minute adjustment to some Metadata VAILDS