User Tools

Site Tools


plugin:inputoutput:dicom_open:start

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
plugin:inputoutput:dicom_open:start [2019/11/17 22:47]
fred
plugin:inputoutput:dicom_open:start [2019/11/21 07:13] (current)
fred
Line 2: Line 2:
 The DICOM_open plugin provides additional functionality on top of the DICOM plugin. ​ There were three main impetuses for developing this plugin, first was to be able to search the DICOM files for a series to open, second was to open the series and get at the actual voxel data, and, third was to properly arrange the images in a hyperstack.  ​ The DICOM_open plugin provides additional functionality on top of the DICOM plugin. ​ There were three main impetuses for developing this plugin, first was to be able to search the DICOM files for a series to open, second was to open the series and get at the actual voxel data, and, third was to properly arrange the images in a hyperstack.  ​
  
-DICOM datasets, that I generally come across, are stored in a hierarchical directory structure in which the directory names do not enlighten the content. ​ The DICOM files are database entries, and the parameters within hold the clues to which datasets may be desired. ​ This plugin'​s GUI provides an interactive interface to find the series of interest to open.  For dealing with a single hodgepodge directory of DICOM files, see DICOM_explode plugin.+DICOM datasets, that I generally come across, are stored in a hierarchical directory structure in which the directory names do not enlighten the content. ​ The DICOM files are database entries, and the parameters within hold the clues to which datasets may be desired. ​ This plugin'​s GUI provides an interactive interface to find the series of interest to open.  For dealing with a single hodgepodge directory of DICOM files, see [[plugin:​utilities:​dicom_explode:​start|DICOM_explode plugin]].
  
 MRI DICOM dataset'​s voxel data tends to be stored as 16 bit unsigned integers, i.e., magnitude data, albeit, the tags within the DICOM files say they are signed. ​ ImageJ does not support signed 16 bit image data.  For some reason, they add 32768 to the dataset voxel values and store them in unsigned 16 bit integer ShortProcessor(s);​ confusing to say the least. ​ This plugin provides the means to access the voxel data as someone who deals with MRI data would expect. MRI DICOM dataset'​s voxel data tends to be stored as 16 bit unsigned integers, i.e., magnitude data, albeit, the tags within the DICOM files say they are signed. ​ ImageJ does not support signed 16 bit image data.  For some reason, they add 32768 to the dataset voxel values and store them in unsigned 16 bit integer ShortProcessor(s);​ confusing to say the least. ​ This plugin provides the means to access the voxel data as someone who deals with MRI data would expect.
Line 27: Line 27:
 Return the DICOM tag/value mappings in easy to use format. ​ The slice ''​s''​ is as returned by ''​ImagePlus.getStackIndex''​. Return the DICOM tag/value mappings in easy to use format. ​ The slice ''​s''​ is as returned by ''​ImagePlus.getStackIndex''​.
  
-''​public static ImagePlus openDICOMShort(File dfs)''​\\ 
-''​public static ImagePlus openDICOMShort(File[] dfs)''​\\ 
 ''​public static ImagePlus openDICOMFloat(File dfs)''​\\ ''​public static ImagePlus openDICOMFloat(File dfs)''​\\
 ''​public static ImagePlus openDICOMFloat(File[] dfs)''​\\ ''​public static ImagePlus openDICOMFloat(File[] dfs)''​\\
 ''​public static ImagePlus openDICOMScaled(File dfs)''​\\ ''​public static ImagePlus openDICOMScaled(File dfs)''​\\
 ''​public static ImagePlus openDICOMScaled(File[] dfs)''​\\ ''​public static ImagePlus openDICOMScaled(File[] dfs)''​\\
-''​public static ImagePlus openDICOM(File ​f, String format)''​\\ +''​public static ImagePlus openDICOMShort(File dfs)''​\\ 
-''​public static ImagePlus openDICOM(File[] ​images, String format)''​\\+''​public static ImagePlus openDICOMShort(File[] dfs)''​\\ 
 +''​public static ImagePlus openDICOM(File ​dfs, String format)''​\\ 
 +''​public static ImagePlus openDICOM(File[] ​dfs, String format)''​\\
 These methods open a DICOM dataset. ​ All but the last one are convenience methods that call the last one.  The DICOM dataset is not yet sorted. ​ With ''​File dfs'',​ ''​dfs''​ can be either the parent directory of the DICOM files or a single DICOM file.  For ''​File[] dfs'',​ ''​dfs''​ should be an array of DICOM files. These methods open a DICOM dataset. ​ All but the last one are convenience methods that call the last one.  The DICOM dataset is not yet sorted. ​ With ''​File dfs'',​ ''​dfs''​ can be either the parent directory of the DICOM files or a single DICOM file.  For ''​File[] dfs'',​ ''​dfs''​ should be an array of DICOM files.
  
Line 47: Line 47:
  
 ''​public static ImagePlus[] diffusionDICOM(ImagePlus imp) throws Exception''​\\ ''​public static ImagePlus[] diffusionDICOM(ImagePlus imp) throws Exception''​\\
-Sorts a multi b-value diffusion dataset into a array of 4 hyperstacks,​ one entry for each of "​Trace","​R/​L","​A/​P","​S/​I"​. ​ Only the array elements that existed in imp are filled in.+Sorts a multi b-value diffusion dataset into a array of 4 hyperstacks,​ one array element ​for each of "​Trace","​R/​L","​A/​P","​S/​I"​. ​ Only the array elements that existed in imp are filled in.
  
 ''​public static double[] ​ getArray(ImagePlus imp, int s, String tag)''​\\ ''​public static double[] ​ getArray(ImagePlus imp, int s, String tag)''​\\
Line 57: Line 57:
  
 ===== Install ===== ===== Install =====
-Place the file {{ :​plugin:​inputoutput:​dicom_open:​dicom_open.java |DICOM_open.java}} in your plugins directory, then compile&​run;​ or just place the {{ :​plugin:​inputoutput:​dicom_open:​dicom_open.class |DICOM_open.class}} file in your plugins directory and refresh the menus / restart ImageJ. ​ Note that DICOM should be in uppercase in the file names.+Place the file {{ :​plugin:​inputoutput:​dicom_open:​dicom_open.java |DICOM_open.java}} in your plugins directory, then compile&​run;​ or just place the {{ :​plugin:​inputoutput:​dicom_open:​dicom_open.class |DICOM_open.class}} file in your plugins directory and refresh the menus / restart ImageJ.  ​**Note that DICOM should be in uppercase in the file names.**
  
 ===== Licence ===== ===== Licence =====
plugin/inputoutput/dicom_open/start.1574027265.txt.gz · Last modified: 2019/11/17 22:47 by fred