dke-questions
dke-questions > After using Matlab to change DICOM sequence name, new problem appear while running DKE
Apr 27, 2018 12:04 PM | Xinman Liu
After using Matlab to change DICOM sequence name, new problem appear while running DKE
Hello, everyone. Sorry to post again because my problem is not
solved yet.
So at first the process of running DKE stopped because my SequenceName and the console window reads: Converting input DICOM images to NIfTI... Error using spm_dicom_convert_series_description>nii_name (line 1186)
Invalid sequence name in DICOM header! Sequence name must contain 'ep'! And later I confirmed it with Matlab and it did show that my SequenceName contains no ' ep'
Then I use following lines in Matlab to change the sequence name of my DICOM data sucessfully.
info=dicominfo('1.3.12.2.1107.5.2.32.35420.2018010410543453162206454');
info.SequenceName = '*ep_b0';
dbstop if error
filenames = dir('*.dcm');
for i = 1: size(filenames,1)
X =dicomread(filenames(i).name);
info = dicominfo(filenames(i).name);
info.SequenceName = '*ep_b0';
% fname= ['./result/',info.MediaStorageSOPInstanceUID, '.dcm'];
fname= strcat('test',num2str(i), '.dcm');
dicomwrite(X, fname ,info)
end
So after finishing changing the SequenceName, new problems appear, and it still doesn't work. The console window reads as following:
% Fri Apr 27 01:54:55 PM
studydir = 'F:\P8';
subject_list = {''};
preprocess_options.format = 'dicom';
preprocess_options.navg = 1;
preprocess_options.extra_b0 = 0;
preprocess_options.coreg_flag = 1;
preprocess_options.series_description = {'ep2d_diff_log2_iso20_free42_B1000_p2'};
fn_img_prefix = 'rdki';
bval = [0 1000 2000];
ndir = 30;
idx_1st_img = 1;
Kmin = 0;
NKmax = 3;
Kmin_final = 0;
Kmax_final = 3;
T = 50;
find_brain_mask_flag = 1;
dki_method.no_tensor = 0;
dki_method.linear_weighting = 1;
dki_method.linear_constrained = 1;
dki_method.nonlinear = 0;
dki_method.linear_violations = 0;
dki_method.robust_option = 0;
dki_method.noise_tolerance = 0.09;
dti_method.dti_flag = 0;
dti_method.dti_only = 0;
dti_method.no_tensor = 0;
dti_method.linear_weighting = 1;
dti_method.b_value = 1e+003;
dti_method.directions{1} = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30];
dti_method.robust_option = 0;
dti_method.noise_tolerance = 0.09;
fn_noise = '';
fwhm_img = [3.375 3.375 3.375];
fwhm_noise = [0 0 0];
median_filter_method = 2;
map_interpolation_method.flag = 0;
map_interpolation_method.order = 1;
map_interpolation_method.resolution = 1;
fn_gradients = 'gradient_vectors_siemens30.dat';
idx_gradients{1} = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30];
idx_gradients{2} = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30];
command line: dke DKEParameters.dat
Diffusional Kurtosis Estimator (DKE) version 2.6.0, February 2015
Start date and time: April 27, 2018 13:55:07
Diffusional Kurtosis Estimator (DKE) version 2.6.0
Converting input DICOM images to NIfTI... ***************************************************
* The AcquisitionNumber counter does not appear *
* to be changing from one volume to another. *
* Another possible explanation is that the same *
* DICOM slices are used multiple times. *
* The conversion is having to guess how slices *
* should be arranged into volumes. *
* NCH_PROGLIO_001 / 9 / 1
***************************************************
complete.
Co-registering images...
Error using spm_hist2
Wrong number of dims (1).
Error in spm_coreg>optfun (line 165)
Error in spm_coreg (line 88)
Error in spm_powell (line 27)
Error in spm_coreg (line 143)
Error in dke_preprocess_dicom>coregister (line 207)
Error in dke_preprocess_dicom (line 78)
Reading input images... Error using dke_estimate (line 165)
Input NIfTI image F:\P8\intermediate_processing\combined\rdki does not exist!
Error in dke (line 182)
Does anyone know what is going on? I'm in desperate need of some suggestions!! Thank you very much.
Best regards,
Xinman
So at first the process of running DKE stopped because my SequenceName and the console window reads: Converting input DICOM images to NIfTI... Error using spm_dicom_convert_series_description>nii_name (line 1186)
Invalid sequence name in DICOM header! Sequence name must contain 'ep'! And later I confirmed it with Matlab and it did show that my SequenceName contains no ' ep'
Then I use following lines in Matlab to change the sequence name of my DICOM data sucessfully.
info=dicominfo('1.3.12.2.1107.5.2.32.35420.2018010410543453162206454');
info.SequenceName = '*ep_b0';
dbstop if error
filenames = dir('*.dcm');
for i = 1: size(filenames,1)
X =dicomread(filenames(i).name);
info = dicominfo(filenames(i).name);
info.SequenceName = '*ep_b0';
% fname= ['./result/',info.MediaStorageSOPInstanceUID, '.dcm'];
fname= strcat('test',num2str(i), '.dcm');
dicomwrite(X, fname ,info)
end
So after finishing changing the SequenceName, new problems appear, and it still doesn't work. The console window reads as following:
% Fri Apr 27 01:54:55 PM
studydir = 'F:\P8';
subject_list = {''};
preprocess_options.format = 'dicom';
preprocess_options.navg = 1;
preprocess_options.extra_b0 = 0;
preprocess_options.coreg_flag = 1;
preprocess_options.series_description = {'ep2d_diff_log2_iso20_free42_B1000_p2'};
fn_img_prefix = 'rdki';
bval = [0 1000 2000];
ndir = 30;
idx_1st_img = 1;
Kmin = 0;
NKmax = 3;
Kmin_final = 0;
Kmax_final = 3;
T = 50;
find_brain_mask_flag = 1;
dki_method.no_tensor = 0;
dki_method.linear_weighting = 1;
dki_method.linear_constrained = 1;
dki_method.nonlinear = 0;
dki_method.linear_violations = 0;
dki_method.robust_option = 0;
dki_method.noise_tolerance = 0.09;
dti_method.dti_flag = 0;
dti_method.dti_only = 0;
dti_method.no_tensor = 0;
dti_method.linear_weighting = 1;
dti_method.b_value = 1e+003;
dti_method.directions{1} = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30];
dti_method.robust_option = 0;
dti_method.noise_tolerance = 0.09;
fn_noise = '';
fwhm_img = [3.375 3.375 3.375];
fwhm_noise = [0 0 0];
median_filter_method = 2;
map_interpolation_method.flag = 0;
map_interpolation_method.order = 1;
map_interpolation_method.resolution = 1;
fn_gradients = 'gradient_vectors_siemens30.dat';
idx_gradients{1} = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30];
idx_gradients{2} = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30];
command line: dke DKEParameters.dat
Diffusional Kurtosis Estimator (DKE) version 2.6.0, February 2015
Start date and time: April 27, 2018 13:55:07
Diffusional Kurtosis Estimator (DKE) version 2.6.0
Converting input DICOM images to NIfTI... ***************************************************
* The AcquisitionNumber counter does not appear *
* to be changing from one volume to another. *
* Another possible explanation is that the same *
* DICOM slices are used multiple times. *
* The conversion is having to guess how slices *
* should be arranged into volumes. *
* NCH_PROGLIO_001 / 9 / 1
***************************************************
complete.
Co-registering images...
Error using spm_hist2
Wrong number of dims (1).
Error in spm_coreg>optfun (line 165)
Error in spm_coreg (line 88)
Error in spm_powell (line 27)
Error in spm_coreg (line 143)
Error in dke_preprocess_dicom>coregister (line 207)
Error in dke_preprocess_dicom (line 78)
Reading input images... Error using dke_estimate (line 165)
Input NIfTI image F:\P8\intermediate_processing\combined\rdki does not exist!
Error in dke (line 182)
Does anyone know what is going on? I'm in desperate need of some suggestions!! Thank you very much.
Best regards,
Xinman
Threaded View
| Title | Author | Date |
|---|---|---|
| Xinman Liu | Apr 27, 2018 | |
| Kirk Feindel | Apr 27, 2018 | |
| Xinman Liu | Apr 29, 2018 | |
| Emilie McKinnon | Apr 27, 2018 | |
| Xinman Liu | Apr 29, 2018 | |
| David Lewis | May 2, 2018 | |
| David Lewis | May 2, 2018 | |
| Xinman Liu | May 3, 2018 | |
| David Lewis | May 3, 2018 | |
| Xinman Liu | May 4, 2018 | |
| Emilie McKinnon | May 4, 2018 | |
| Xinman Liu | May 5, 2018 | |
| Xinman Liu | May 3, 2018 | |
| David Lewis | May 3, 2018 | |
