Error using ocssw calibration on VIIRS

Use this Forum to find information on, or ask a question about, NASA Earth Science data.
Post Reply
slsmit34
Posts: 23
Joined: Thu May 18, 2023 10:29 am America/New_York
Answers: 0

Error using ocssw calibration on VIIRS

by slsmit34 » Mon Oct 21, 2024 4:30 pm America/New_York

Hello,
I know I have asked many l2gen questions in the past week, so thank you in advance for your patience.

I am currently trying to run l2gen on L1A VIIRS-SNPP data (scene: SNPP_VIIRS.20230712T180000.L1A.nc). I am starting by running calibrate_viirs on the L1A scene to generate L1B. To do this, I did

Code: Select all

install_ocssw -t V2024.6 --viirsn --viirs_l1 --install_dir /path/l2gen/ocssw
which installed folders viirsj1 and viirsn files to /ocssw/var, viirs to /ocssw/share, and viirs_l1_benchmark to /ocssw. It also output the following:
downloaded_ocssw.PNG
downloaded_ocssw.PNG (34.42 KiB) Not viewed yet


However, I get this error when running calibrate_viirs:
calibrate_viirs_error.PNG
calibrate_viirs_error.PNG (81.24 KiB) Not viewed yet
By the way, polar_wander.ascii does exist in my directory /ocssw/var/viirsn and has a size of 2.2MB.

Thank you!
Best,
Sami

Filters:

OB ODPS - towens
Subject Matter Expert
Subject Matter Expert
Posts: 451
Joined: Fri Feb 05, 2021 9:17 am America/New_York
Answers: 0
Been thanked: 7 times

Re: Error using ocssw calibration on VIIRS

by OB ODPS - towens » Mon Oct 21, 2024 9:58 pm America/New_York

Are you setting the correct environment?
export OCSSWROOT=path_to_your_ocssw_directory
export OCVARROOT=$OCSSWROOT/var

We stage the operational GEO files so you don't have to make them.
Replace "L1A" with "GEO" in the filename.

Tommy

slsmit34
Posts: 23
Joined: Thu May 18, 2023 10:29 am America/New_York
Answers: 0

Re: Error using ocssw calibration on VIIRS

by slsmit34 » Tue Oct 22, 2024 12:52 pm America/New_York

Hi Tommy,
Thanks. So if I am understanding correctly, I can download the GEO file and use that as a parameter for l2gen? Do I still need to generate L1B with calibrate_viirs then? Can I just generate an l2 directly from l1a with a command like this:

Code: Select all

"l2gen ifile={l1a_file} ofile={output_name} geofile={geo_file}"
Is there a need to use getanc or calibrate_viirs then?

Best,
Sami

OB ODPS - towens
Subject Matter Expert
Subject Matter Expert
Posts: 451
Joined: Fri Feb 05, 2021 9:17 am America/New_York
Answers: 0
Been thanked: 7 times

Re: Error using ocssw calibration on VIIRS

by OB ODPS - towens » Tue Oct 22, 2024 1:25 pm America/New_York

Yes, to make an L2 file you should provide the ancillary data. We make an L1B file from the L1A and GEO and then pass the L1B to l2gen.
I think l2gen has the code to make L2 directly from L1A and GEO but I will defer to one of our SeaDAS experts on running that...

Tommy

OB.DAACx - SeanBailey
Posts: 1519
Joined: Wed Sep 18, 2019 6:15 pm America/New_York
Answers: 1
Been thanked: 9 times

Re: Error using ocssw calibration on VIIRS

by OB.DAACx - SeanBailey » Tue Oct 22, 2024 1:41 pm America/New_York

Yes, l2gen can take a VIIRS L1A file as input (performing the calibration on-the-fly), but the VIIRS geolocation and calibration programs share code, so if you are unable to process the geoocation, you will likely have issues calibrating - either with calibrate_viirs or l2gen.

Sean

slsmit34
Posts: 23
Joined: Thu May 18, 2023 10:29 am America/New_York
Answers: 0

Re: Error using ocssw calibration on VIIRS

by slsmit34 » Tue Oct 22, 2024 2:00 pm America/New_York

Thanks all for the support.
So the process to go from L1A to L2 includes two steps, each with ifile, ofile, and geofile: Is this correct? I'm not sure where getanc goes in this process.

OB.DAACx - SeanBailey
Posts: 1519
Joined: Wed Sep 18, 2019 6:15 pm America/New_York
Answers: 1
Been thanked: 9 times

Re: Error using ocssw calibration on VIIRS

by OB.DAACx - SeanBailey » Wed Oct 23, 2024 6:59 am America/New_York

Yes, that is the process. The getanc call goes before l2gen to identify (and download) the ancillary inputs to the l2gen process. BTW, calibrate_viirs can output three different files, thus in place of ofile it uses l1bfile_[img,mod,dnb].

BTW, the calibrate_viirs code includes the bits of the geolocation code necessary to do the calibration, so a geofile is not required as input...which is why I said in my previous post that if geolocate_viirs fails due to an incorrect configuration or missing LUTs, calibrate_viirs is also likely to fail.

Sean

Post Reply