Hi all,
I’m processing some Siemens ima data that has not had oversampling removed, which seems to confuse both Tarquin and Osprey.
For Osprey, the following hack (in io_loadspec_dicom.m) avoids errors and incorrect spectral width:
fids = zeros(DicomHeader.vectorSize*2,length(filesInFolder)); % MJT HACK
dwelltime = DicomHeader.dwellTime * 1e-9 * 1; % MJT HACK
(basically, I’m overriding the logic that detects oversampling removal)
For Tarquin, I copied and modified the ima files using python:
data_ws = ‘./svs.dcm’
data_ws_mod = ‘./svs_mod.dcm’
with open(data_ws,“rb”) as f:
s=f.read()
f.close()
assert s.find(b’sRXSPEC.alDwellTime[0] = 250000’) != -1 # check that dwell time is found and as expected
s=s.replace(b’sRXSPEC.alDwellTime[0] = 250000’,b’sRXSPEC.alDwellTime[0] = 125000’)
with open(data_ws_mod,“wb”) as f:
f.write(s)
(Correcting the sampling frequency via the GUI also works, but it didn’t work as a command line option.)
Sharing this in case it’s useful to users or developers.
Michael