Skip to content

Commit

Permalink
adjustments in paths in config files due to availablitity of external…
Browse files Browse the repository at this point in the history
… data
  • Loading branch information
bohlinger committed Dec 4, 2024
1 parent 9f2974a commit a3b8239
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 16 deletions.
20 changes: 10 additions & 10 deletions tests/test_satellite_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,16 @@ def test_collectors_cci_v3_20Hz(tmpdir):
if '.nc' in filelist[i]]
assert len(nclist) >= 1

@pytest.mark.need_credentials
def test_collectors_cci_v1_01Hz(tmpdir):
sco = sc(sd='2018-1-1', ed='2018-1-1',
nID='CCIv1_L3', name='multi')
sco.download(path=tmpdir, nproc=8)
# check if files were download to tmp directory
filelist = os.listdir(tmpdir)
nclist = [i for i in range(len(filelist))
if '.nc' in filelist[i]]
assert len(nclist) >= 1
#@pytest.mark.need_credentials
#def test_collectors_cci_v1_01Hz(tmpdir):
# sco = sc(sd='2018-1-1', ed='2018-1-1',
# nID='CCIv1_L3', name='multi')
# sco.download(path=tmpdir, nproc=8)
# # check if files were download to tmp directory
# filelist = os.listdir(tmpdir)
# nclist = [i for i in range(len(filelist))
# if '.nc' in filelist[i]]
# assert len(nclist) >= 1

#@pytest.mark.need_credentials
#def test_collectors_aviso(tmpdir):
Expand Down
7 changes: 5 additions & 2 deletions wavy/config/model_cfg.yaml.default
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,11 @@ ARCMFC3:
lats: lat
coords:
wavy_input:
src_tmplt: "https://thredds.met.no/thredds/dodsC/\
cmems/mywavewam3km_files/%Y/%m/"
#src_tmplt: "https://thredds.met.no/thredds/dodsC/\
# cmems/mywavewam3km_files/%Y/%m/"
#src_tmplt: "/lustre/storeA/project/copernicus/sea/mywavewam3_c47_new/arctic/%Y/%m/"
src_tmplt: "/lustre/storeA/project/copernicus/sea\
/mywavewam3_preop/arctic/%Y/%m/"
# Best guess: 2019071500_MyWaveWam3_b20190715T06.nc
# - This is actually 2019071500_*_b20190715T00* but due
# to delay the bulletin date/time is adjusted
Expand Down
61 changes: 57 additions & 4 deletions wavy/config/satellite_cfg.yaml.default
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ CCIv3_L3:
# where to store downloaded data
download:
ftp: # downloading method
src_tmplt:
src_tmplt: /products/v3/data/satellite/altimeter/l3/%Y/%j/
trgt_tmplt:
strsub:
server:
Expand Down Expand Up @@ -364,6 +364,59 @@ CCIv3_L3:
# optional, to ease grouping
tags:

CCIv3_L3_20Hz:
# mandatory
name:
S3A: S3A
# mandatory when downloading
# where to store downloaded data
download:
ftp: # downloading method
src_tmplt: "/products/v3/data/satellite/altimeter\
/l2_20Hz/l2/sentinel-3_a/%Y/%j/"
trgt_tmplt:
strsub:
server:
path_date_incr_unit:
path_date_incr:
search_str:
# optional: where to read from
# can be defined directly when calling wavy
wavy_input:
#src_tmplt: /lustre/storeB/project/fou/om/patrikb/CCIv3_01Hz/%Y/%m/
src_tmplt:
fl_tmplt:
strsub: ["nID"]
path_date_incr_unit: 'm'
path_date_incr: 1
# optional: where to write to
# can be defined directly when calling wavy
wavy_output:
trgt_tmplt: /home/patrikb/tmp_altimeter/L3/nID/name/%Y/%m/
fl_tmplt: "varalias_name_region_\
%Y%m%d%H%M%S_%Y%m%d%H%M%S.nc"
strsub: ['varalias','name','region','nID']
file_date_incr_unit: 'd'
file_date_incr: 1
# optional, if not defined the default is used
reader: read_local_ncfiles
collector:
# optional, needs to be defined if not cf and in variable_info.yaml
vardef: # varalias: varname
Hs: swh_denoised
dtc: distance_to_coast
time: time
lats: lat
lons: lon
coords:
# optional, info that can be used by class functions
misc:
processing_level: L3
provider: cci
obs_type:
# optional, to ease grouping
tags:

s3a_sla_5Hz:
# mandatory
name:
Expand Down Expand Up @@ -423,12 +476,12 @@ cfo_swim:
# where to store downloaded data
download:
ftp: # downloading method
src_tmplt: "/cfosat/swim_l2p_box_nrt/%Y/%m/"
trgt_tmplt: "/home/patrikb/tmp_altimeter/nID/name/%Y/%m/"
src_tmplt: "/cfosat_products/swim_l2p_box_nrt/%Y/"
trgt_tmplt: "/home/patrikb/tmp_altimeter/nID/name/%Y/"
path_date_incr_unit: 'm'
path_date_incr: 1
search_str: '%Y%m%dT'
strsub: ['name']
strsub: ['nID','name']
server: "ftp-access.aviso.altimetry.fr"
# optional: where to read from
# can be defined directly when calling wavy
Expand Down

0 comments on commit a3b8239

Please sign in to comment.