Wrong valid_max attribute for ipar

Use this Forum to find information on, or ask a question about, NASA Earth Science data.
Post Reply
gbourdin
Posts: 34
Joined: Mon Jan 25, 2021 11:59 am America/New_York
Answers: 0
Has thanked: 1 time

Wrong valid_max attribute for ipar

by gbourdin » Tue Jul 18, 2023 1:38 am America/New_York

Hi all,
I was missing all ipar data after running l2gen on MODISA, MODIST, and OLCI. I noticed l2gen is defining the wrong "valid_max" attribute for ipar, both "valid_min = 0" and "valid_max = 0".
I found a workaround forcing "valid_max = 30000" to prevent ipar data to disappear during the next step of my processing.
Just wanted to know if I am the only one having this problem?
I am using OCSSW V2023.2
Best,
Guillaume

Tags:

OB SeaDAS - xuanyang02
Subject Matter Expert
Subject Matter Expert
Posts: 657
Joined: Tue Feb 09, 2021 5:42 pm America/New_York
Answers: 1
Been thanked: 2 times

Re: Wrong valid_max attribute for ipar

by OB SeaDAS - xuanyang02 » Tue Jul 18, 2023 12:39 pm America/New_York

I have valid ipar data after running l2gen on A2023164100000.L1A_LAC.
gbourdin wrote: Tue Jul 18, 2023 1:38 am America/New_York I noticed l2gen is defining the wrong "valid_max" attribute for ipar, both "valid_min = 0" and "valid_max = 0".
I looked at ipar in ocssw/share/common/product.xml, but did not see "valid_max=0". Where did you change "valid_max=0" to "valid_max=30000"?

gbourdin
Posts: 34
Joined: Mon Jan 25, 2021 11:59 am America/New_York
Answers: 0
Has thanked: 1 time

Re: Wrong valid_max attribute for ipar

by gbourdin » Wed Jul 19, 2023 3:04 am America/New_York

The "valid_max=0" is in the attributes of the ipar variable in the output L2 netCDF file.
I also looked at ipar in ocssw/share/common/product.xml and I have a good max value:

Code: Select all

    </product>
    <product name="ipar">
        <standardName>downwelling_photosynthetic_photon_radiance_in_sea_water</standardName>
        <units>einstein m^-2 s^-1</units>
        <category>Derived</category>
        <type>short</type>
        <range>
            <displayMin>0</displayMin>
            <displayMax>0.0025</displayMax>
            <scaleFactor>1e-07</scaleFactor>
            <addOffset>0</addOffset>
        </range>
        <algorithm>
            <cat_ix>84</cat_ix>
            <description>Instantaneous Photosynthetically Available Radiation</description>
        </algorithm>
I am not sure where is the problem coming from but all (several hundreds) L2 images out of l2gen have this problem.
Best,
Guillaume

OB SeaDAS - xuanyang02
Subject Matter Expert
Subject Matter Expert
Posts: 657
Joined: Tue Feb 09, 2021 5:42 pm America/New_York
Answers: 1
Been thanked: 2 times

Re: Wrong valid_max attribute for ipar

by OB SeaDAS - xuanyang02 » Wed Jul 19, 2023 2:54 pm America/New_York

The issue is that valid_min and valid_max for ipar are not defined in product.xml, and l2gen assigned 0 to valid_min and valid_max by default. We'll fix the issue for the next V tag.

In the mean time, you can change valid_min and valid_max in product.xml, so l2gen will create L2 files with valid_min and valid_max for ipar that you defined.

However, the L2 files generated by l2gen should have valid ipar data if you display the ipar band with SeaDAS GUI.

gbourdin
Posts: 34
Joined: Mon Jan 25, 2021 11:59 am America/New_York
Answers: 0
Has thanked: 1 time

Re: Wrong valid_max attribute for ipar

by gbourdin » Wed Jul 19, 2023 6:08 pm America/New_York

Perfect thank you! I will make it work until the next V tag.
I guess I noticed the issue because I am not using the GUI.
Best,
Guillaume

Post Reply