How to automatically choose and download ancillary data when run ocssw with parfile

Please enter here to ask a question about any NASA Science related topics!
Post Reply
roxani2018
Posts: 5
Joined: Fri Jan 29, 2021 11:42 am America/New_York

How to automatically choose and download ancillary data when run ocssw with parfile

by roxani2018 » Thu Feb 04, 2021 4:46 am America/New_York

Hi!

I use SeaDAS-7.5.3 (on MacOS 10.13.6) to batch process GOCI L1B data based on parfile. However, I am not clear how can I make it automatically choose and download ancillary data when dealing with different input file (L1B file in different time).

More specifically, for instance, when ifile = COMS_GOCI_L1B_GA_20110402001644.he5, I hope it can choose following files (closest in time) and download (it is acceptable if impossible to download) them in specific path:
icefile = N201109100_SEAICE_NSIDC_24h.hdf
met1 = N201109200_MET_NCEPR2_6h.hdf
met2 = N201109206_MET_NCEPR2_6h.hdf
met3 = N201109206_MET_NCEPR2_6h.hdf
ozone1 = N201109100_O3_AURAOMI_24h.hdf
ozong2 = N201109200_O3_AURAOMI_24h.hdf
ozone3 = N201109200_O3_AURAOMI_24h.hdf
sstfile = N2011091_SST_OIV2AVAM_24h.nc

The parfile I wrote are as follows:
# PRIMARY INPUT OUTPUT FIELDS
ifile=/Users/me/Desktop/COMS_GOCI_L1B_GA_20110402001644.he5
ofile=/Users/me/Desktop/G2011092001538.L2_LAC_OC
# SUITE
suite=OC
# PRODUCTS
l2prod=humidity nLw nLw_nnn
# ANCILLARY INPUTS  Default = climatology (select 'Get Ancillary' to download ancillary files)
ancdb=/Applications/seadas-7.5.3/ocssw/var/anc/ancillary.db

When I run with above parfile, it seems still use default climatology data to handle L1B data, rather than my new settings. I am wondering if I made any mistakes or is it the right way to achieve the goal???

Sorry to bother and wait for reply.

Tags:

sdsuhjy
Posts: 1
Joined: Mon Feb 01, 2021 8:49 am America/New_York

How to automatically choose and download ancillary data when run ocssw with parfile

by sdsuhjy » Thu Feb 04, 2021 4:58 am America/New_York

I also met the similar problem, and wonder how to write the parfile correctly??

OB SeaDAS - dshea
Subject Matter Expert
Subject Matter Expert
Posts: 214
Joined: Thu Mar 05, 2009 10:25 am America/New_York

How to automatically choose and download ancillary data when run ocssw with parfile

by OB SeaDAS - dshea » Thu Feb 04, 2021 9:32 am America/New_York

There is a program called "getanc" that will download the ancillary files and create a par file for you given the input file.  On the command line run this:

getanc COMS_GOCI_L1B_GA_20110402001644.he5

ancillary_data.db
Encountered more than 1 Scene Start time tag. Using 1st value.
Encountered more than 1 Scene end time tag. Using 1st value.
icefile=/accounts/dshea/ocssw/var/anc/2011/091/N201109100_SEAICE_NSIDC_24h.hdf
met1=/accounts/dshea/ocssw/var/anc/2011/092/N201109200_MET_NCEPR2_6h.hdf
met2=/accounts/dshea/ocssw/var/anc/2011/092/N201109206_MET_NCEPR2_6h.hdf
met3=/accounts/dshea/ocssw/var/anc/2011/092/N201109206_MET_NCEPR2_6h.hdf
ozone1=/accounts/dshea/ocssw/var/anc/2011/091/N201109100_O3_AURAOMI_24h.hdf
ozone2=/accounts/dshea/ocssw/var/anc/2011/092/N201109200_O3_AURAOMI_24h.hdf
ozone3=/accounts/dshea/ocssw/var/anc/2011/092/N201109200_O3_AURAOMI_24h.hdf
sstfile=/accounts/dshea/ocssw/var/anc/2011/091/N2011091_SST_OIV2AVAM_24h.nc

The program downloads the above files and creates a par file to set the ancillary parameters for l2gen.  The par file created by default is <inputFile>.anc 
In this case COMS_GOCI_L1B_GA_20110402001644.he5.anc

Now you can run l2gen like this:

l2gen par=<yourParFile> par=COMS_GOCI_L1B_GA_20110402001644.he5.anc

I would just use the default location for the ancdb, so do not set the "ancdb" parameter in your par file.

don

roxani2018
Posts: 5
Joined: Fri Jan 29, 2021 11:42 am America/New_York

How to automatically choose and download ancillary data when run ocssw with parfile

by roxani2018 » Thu Feb 04, 2021 9:53 pm America/New_York

Hi Don,
It works. Thanks  so much!
Best,
roxani

Post Reply