Skip to content

Commit

Permalink
Merge pull request #592 from pulupa/master
Browse files Browse the repository at this point in the history
support additional data types
  • Loading branch information
jameswilburlewis authored Sep 27, 2023
2 parents 192d728 + d846b64 commit 18c4730
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pyspedas/psp/load.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ def load(trange=['2018-11-5', '2018-11-6'],
pathformat = instrument + '/' + level + '/mag_sc_4_per_cycle/%Y/psp_fld_' + level + '_mag_sc_4_sa_per_cyc_%Y%m%d_v??.cdf'
elif datatype == 'sqtn_rfs_v1v2':
pathformat = instrument + '/' + level + '/' + datatype + '/%Y/psp_fld_' + level + '_' + datatype + '_%Y%m%d_v?.?.cdf'
elif datatype == 'rfs_lfr_qtn':
pathformat = instrument + '/' + level + '/' + datatype + '/%Y/psp_fld_' + level + '_' + datatype + '_%Y%m*_v??.cdf'
elif datatype in ['dfb_dc_spec', 'dfb_ac_spec', 'dfb_dc_xspec', 'dfb_ac_xspec']:
out_vars = []
for item in spec_types:
Expand Down Expand Up @@ -97,6 +99,9 @@ def load(trange=['2018-11-5', '2018-11-6'],
elif datatype == 'sqtn_rfs_V1V2':
pathformat = instrument + '/' + level + '/' + datatype + '/%Y/%m/psp_fld_' + level + '_' + datatype + '_%Y%m%d_v?.?.cdf'

else:
pathformat = instrument + '/' + level + '/' + datatype + '/%Y/%m/psp_fld_' + level + '_' + datatype + '_%Y%m%d_v??.cdf'

else:
# Generic SPDF path.
pathformat = instrument + '/' + level + '/' + datatype + '/%Y/psp_fld_' + level + '_' + datatype + '_%Y%m%d%H_v??.cdf'
Expand All @@ -105,6 +110,8 @@ def load(trange=['2018-11-5', '2018-11-6'],
# Files on Berkeley server are stored in monthly directories
if username != None:
pathformat = pathformat.replace('/%Y/psp_fld', '/%Y/%m/psp_fld')
if level == 'l1':
pathformat = pathformat.replace('psp_fld', 'spp_fld')

elif instrument == 'spc':
prefix = 'psp_spc_'
Expand Down

0 comments on commit 18c4730

Please sign in to comment.