Skip to content

Commit 8774a01

Browse files
committed
better fix for ways to identify xspress3 hdf5 file
1 parent cc02403 commit 8774a01

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

larch/xrmmap/gsexrm_utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -201,8 +201,9 @@ def __init__(self, yvalue, xrffile, xrdfile, xpsfile, sisfile, folder,
201201
if has_xrf:
202202
if xrftype is None:
203203
xrftype = 'netcdf'
204-
if (xrffile.startswith('xsp3') or xrffile.startswith('xspress') or
205-
xrffile.endswith('.h5') or xrffile.endsswith('hdf5')):
204+
if (xrffile.startswith('xsp') or
205+
xrffile.endswith('h5') or
206+
xrffile.endswith('hdf5')):
206207
xrftype = 'hdf5'
207208
if xrftype == 'netcdf':
208209
xrf_reader = read_xrf_netcdf
@@ -218,7 +219,6 @@ def __init__(self, yvalue, xrffile, xrdfile, xpsfile, sisfile, folder,
218219
xrd_reader = read_xrd_netcdf
219220

220221
# print( "xrd_reader ", xrd_reader, xrdtype, xrdfile, ' cal :%s: ' % xrdcal)
221-
222222
# reading can fail with IOError, generally meaning the file isn't
223223
# ready for read. Try again for up to 5 seconds
224224

0 commit comments

Comments
 (0)