AFNI Message Board

Dear AFNI users-

We are very pleased to announce that the new AFNI Message Board framework is up! Please join us at:

https://discuss.afni.nimh.nih.gov

Existing user accounts have been migrated, so returning users can login by requesting a password reset. New users can create accounts, as well, through a standard account creation process. Please note that these setup emails might initially go to spam folders (esp. for NIH users!), so please check those locations in the beginning.

The current Message Board discussion threads have been migrated to the new framework. The current Message Board will remain visible, but read-only, for a little while.

Sincerely, AFNI HQ

History of AFNI updates  

|
John
November 16, 2012 04:25PM
AFNIans,

I'm having some trouble getting dimon to correctly put together a directory of DICOM files.

There are 3520 DICOM files, all part of a 4D image with 44 slices per volume and 80 volumes. When I attempt to run dimon on the directory, it only seems to find 77 volumes. I've copied the dimon output below.

The slices all appear to have valid values for temporal position and slice location in the headers. In the directory, they are ordered by temporal position, then in descending slice location (the first file is the slice at the maximum slice location for the first temporal position; the second slice is at the second-to-max slice location for the first temporal position; the 45th file is the slice at the maximum slice location for the second temporal position, etc.).

I've tried using various dimon options (-use_last_elem, -use_slice_loc, -sort_by_acq_time, etc.) but haven't had any luck.

Should I try some other dimon options or attempt to reorder the files in some other way before using dimon? Are there some other header fields that need to be in place for dimon to correctly order the images that I should double-check?

Thanks,
-John

<<<
dimon -debug 2 -infile_prefix ./NC -dicom_org -quit -GERT_Reco -gert_filename test_script -gert_to3d_prefix test_image

Dimon running, use <ctrl-c> to quit...

-- scanning for first volume
-- checking 3520 potential DICOM files... 00%++ Data detected to be oblique
-- is_oblique = 1, is_mosaic = 0
100%
++ found 3520 DICOM files
-- dicom sort : 2 inversions, 0 non-DICOM files, sort type 0x0
(dicom_org was useful)
-d dicom_org complete
++ allocating 32768 bytes for is->x_im
-- scanned 40 image files, from <./NC-1301-003519.dcm> to <./NC-1301-000039.dcm>
-- RGEFa: read 40 files (total 40)
+d cov: returning first, last, delta = 0, 1, 145.617

*************************************************
Error: missing slice(s) in first volume!
attempting to re-start at file: ./NC-1301-000002.dcm
*************************************************
-- volume search returns -1
.-d computed nap_time is 3300 ms (TR = 3.00)
-- scanned 80 image files, from <./NC-1301-000002.dcm> to <./NC-1301-000081.dcm>
-- RGEFa: read 80 files (total 82)
+d cov: returning first, last, delta = 0, 41, -3.46706

*************************************************
Error: missing slice(s) in first volume!
attempting to re-start at file: ./NC-1301-000044.dcm
*************************************************
-- volume search returns -1
.-- scanned 160 image files, from <./NC-1301-000044.dcm> to <./NC-1301-000203.dcm>
-- RGEFa: read 160 files (total 204)
+d cov: returning first, last, delta = 0, 43, -3.46706
+d found first slice of second volume
-- data is oblique
-- volume search returns 1

-- first volume found (44 slices)
+d first volume : vol_t struct at 0x7fff5fbff590 :
nim = 44
(fl_1, fn_1, fn_n) = (0, 44, 87)
first_file = ./NC-1301-000044.dcm
last_file = ./NC-1301-000087.dcm
(z_first, z_last) = (68.8662, -80.2175)
z_delta, image_dz = (-3.46706, 3.5)
oblique = 1
(seq_num, run) = (-1, 1301)
+d first volume : ge_header_info at 0x7fff5fbff590 :
good = 1
(nx,ny) = (128,128)
uv17 = 1301
index = 0
im_index = -1
atime = 80732.343750
slice_loc = 150.500000
(dx,dy,dz) = (1.875,1.875,3.5)
zoff = 68.8662
(tr,te) = (3,0)
orients = RLAPSI
+d first volume : ge_extras at 0x7fff5fbff5d0 :
bpp = 2
cflag = 0
hdroff = -1
skip = -1
swap = 0
kk = 0
xorg = -101.107
yorg = -162.899
(xyz0,xyz1,xyz2) = (0,0,0)
(xyz3,xyz4,xyz5) = (0,0,0)
(xyz6,xyz7,xyz8) = (0,0,0)
+d first volume : mosaic_info at 0x7fff5fbff614 :
is_mosaic = 0
nslices = 0
mos_nx, ny = 0, 0
-- system order is LSB_FIRST, image order is LSB_FIRST
-d computed nap_time is 3300 ms (TR = 3.00)
-- scanning for additional volumes...
-- run 1301: 1
-- svs: init alloc - vol 1, run 1301, file ./NC-1301-000044.dcm

-- svs: realloc (1321 entries) - vol 1, run 1301, file ./NC-1301-000044.dcm
2 -- scanned 176 image files, from <./NC-1301-000176.dcm> to <./NC-1301-000351.dcm>
-- RGEFb: read 176 files
3 4 5 6 -- scanned 176 image files, from <./NC-1301-000352.dcm> to <./NC-1301-000527.dcm>
-- RGEFb: read 176 files
7 8 9 10 -- scanned 176 image files, from <./NC-1301-000528.dcm> to <./NC-1301-000703.dcm>
-- RGEFb: read 176 files
11 12 13 14 -- scanned 176 image files, from <./NC-1301-000704.dcm> to <./NC-1301-000879.dcm>
-- RGEFb: read 176 files
15 16 17 18 -- scanned 176 image files, from <./NC-1301-000880.dcm> to <./NC-1301-001055.dcm>
-- RGEFb: read 176 files
19 20 21 22 -- scanned 176 image files, from <./NC-1301-001056.dcm> to <./NC-1301-001231.dcm>
-- RGEFb: read 176 files
23 24 25 26 -- scanned 176 image files, from <./NC-1301-001232.dcm> to <./NC-1301-001407.dcm>
-- RGEFb: read 176 files
27 28 29 30 -- scanned 176 image files, from <./NC-1301-001408.dcm> to <./NC-1301-001583.dcm>
-- RGEFb: read 176 files
31 32 33 34 -- scanned 176 image files, from <./NC-1301-001584.dcm> to <./NC-1301-001759.dcm>
-- RGEFb: read 176 files
35 36 37 38 -- scanned 176 image files, from <./NC-1301-001760.dcm> to <./NC-1301-001935.dcm>
-- RGEFb: read 176 files
39 40 41 42 -- scanned 176 image files, from <./NC-1301-001936.dcm> to <./NC-1301-002111.dcm>
-- RGEFb: read 176 files
43 44 45 46 -- scanned 176 image files, from <./NC-1301-002112.dcm> to <./NC-1301-002287.dcm>
-- RGEFb: read 176 files
47 48 49 50 -- scanned 176 image files, from <./NC-1301-002288.dcm> to <./NC-1301-002463.dcm>
-- RGEFb: read 176 files
51 52 53 54 -- scanned 176 image files, from <./NC-1301-002464.dcm> to <./NC-1301-002639.dcm>
-- RGEFb: read 176 files
55 56 57 58 -- scanned 176 image files, from <./NC-1301-002640.dcm> to <./NC-1301-002815.dcm>
-- RGEFb: read 176 files
59 60 61 62 -- scanned 176 image files, from <./NC-1301-002816.dcm> to <./NC-1301-002991.dcm>
-- RGEFb: read 176 files
63 64 65 66 -- scanned 176 image files, from <./NC-1301-002992.dcm> to <./NC-1301-003167.dcm>
-- RGEFb: read 176 files
67 68 69 70 -- scanned 176 image files, from <./NC-1301-003168.dcm> to <./NC-1301-003343.dcm>
-- RGEFb: read 176 files
71 72 73 74 -- scanned 176 image files, from <./NC-1301-003344.dcm> to <./NC-1301-000000.dcm>
-- RGEFb: read 176 files
75 76 77 -- scanned 44 image files, from <./NC-1301-003476.dcm> to <./NC-1301-000000.dcm>
-- RGEFb: read 44 files
-- scanned 44 image files, from <./NC-1301-003476.dcm> to <./NC-1301-000000.dcm>
-- RGEFb: read 44 files
. -- scanned 44 image files, from <./NC-1301-003476.dcm> to <./NC-1301-000000.dcm>
-- RGEFc: read 44 files
. -- scanned 44 image files, from <./NC-1301-003476.dcm> to <./NC-1301-000000.dcm>
-- RGEFc: read 44 files
. -- scanned 44 image files, from <./NC-1301-003476.dcm> to <./NC-1301-000000.dcm>
-- RGEFc: read 44 files


final run statistics:
volume info :
slices : 44
z_first : 68.87
z_last : -80.22
z_delta : 3.5
oblique : yes
mos_nslices : 0

run #1301 : volumes = 77, first file (#44) = ./NC-1301-000044.dcm


** have 44 unprocessed image(s)
>>>
Subject Author Posted

Problematic dimon files

John November 16, 2012 04:25PM

Re: Problematic dimon files

John November 26, 2012 01:16PM

Re: Problematic dimon files

rick reynolds November 26, 2012 09:42PM

Re: Problematic dimon files

John November 28, 2012 12:03PM

Re: Problematic dimon files

John Graner December 03, 2012 01:09PM

Re: Problematic dimon files

rick reynolds December 03, 2012 02:02PM

Re: Problematic dimon files

John Graner December 04, 2012 11:27AM

Re: Problematic dimon files

rick reynolds December 05, 2012 12:04PM

Re: Problematic dimon files

John Graner December 05, 2012 04:16PM