Difference between revisions of "Documentation/Nightly/SlicerApplication/SupportedDataFormat"

From Slicer Wiki
Jump to: navigation, search
(Prepend documentation/versioncheck template. See http://na-mic.org/Mantis/view.php?id=2887)
(20 intermediate revisions by 6 users not shown)
Line 12: Line 12:
 
!Module
 
!Module
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Scenes
+
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Scenes
! scope="col"| [[Documentation/{{documentation/version}}/Modules/Data|Data]]
+
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/Data|Data]]
 
|-
 
|-
 
| MRML (Medical Reality Markup Language File)
 
| MRML (Medical Reality Markup Language File)
Line 19: Line 19:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|MRML file is a xml-formatted text file with scene metadata and pointers to externally stored data files. [[Documentation/{{documentation/version}}/Developers/MRML|Data Model]]
+
|MRML file is a xml-formatted text file with scene metadata and pointers to externally stored data files. See [[Documentation/{{documentation/version}}/Developers/MRML|Data Model]]. Coordinate system: RAS
 
|-
 
|-
 
| MRB (Medical Reality Bundle)
 
| MRB (Medical Reality Bundle)
Line 25: Line 25:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes (.mrb extension only)
 
|bgcolor="LightGreen" align="center"|yes (.mrb extension only)
|MRB is a binary format encapsulating all scene data (bulk data and metadata).  Internally it uses zip format.  Any .zip file that contains a self-contained data tree including a .mrml file can be opened.
+
|MRB is a binary format encapsulating all scene data (bulk data and metadata).  Internally it uses zip format.  Any .zip file that contains a self-contained data tree including a .mrml file can be opened. Coordinate system: RAS
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Raster Images<br><small>''this includes 2D and 3D images, and more complicated types such as DWI or DTI''</small>
+
| Slicer 2 Scene
! scope="col"| [[Documentation/{{documentation/version}}/Modules/Volumes|Volumes]]
+
| .xml
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="#f34a33" align="center"|no
 +
| xml-formatted text file with scene metadata and pointers to externally stored data files. Coordinate system: RAS
 +
|-
 +
| Data collections in XNAT Catalog format (".xcat") or XNAT Archive format (".xar")
 +
| .xcat
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="#f34a33" align="center"|no
 +
|
 +
|-
 +
| Data collections in XNAT Archive format (".xar")
 +
| .xar
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="#f34a33" align="center"|no
 +
|
 +
|-
 +
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Raster Images<br><small>''this includes 2D and 3D images, and more complicated types such as DWI or DTI''</small>
 +
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/Volumes|Volumes]]
 
|-
 
|-
 
| [http://medical.nema.org/ DICOM]
 
| [http://medical.nema.org/ DICOM]
 
| .dcm ...
 
| .dcm ...
 
|bgcolor="LightGreen" align="center"|yes<ref>For a number of dMRI formats we recommend use of the [[Documentation/{{documentation/version}}/Modules/DicomToNrrdConverter|DICOM to NRRD converter]] before loading the data into Slicer.</ref>
 
|bgcolor="LightGreen" align="center"|yes<ref>For a number of dMRI formats we recommend use of the [[Documentation/{{documentation/version}}/Modules/DicomToNrrdConverter|DICOM to NRRD converter]] before loading the data into Slicer.</ref>
|bgcolor="#f34a33" align="center"|no<ref>Limited support for writing image volumes in DICOM format is provided by the [[Documentation/{{documentation/version}}/Modules/CreateDICOMSeries|Create DICOM Series]] module. Support of writing DICOM Segmentation Objects is provided by the [[Documentation/{{documentation/version}}/Extensions/Reporting|Reporting extension]]</ref>
+
|bgcolor="LightGreen" align="center"|yes (some data types)<ref>Image volumes, RT structure sets, dose volumes, etc. can be exported using [[Documentation/{{documentation/version}}/Modules/DICOM#DICOM_export|DICOM module's export feature]]. Limited support for writing image volumes in DICOM format is provided by the [[Documentation/{{documentation/version}}/Modules/CreateDICOMSeries|Create DICOM Series]] module. Support of writing DICOM Segmentation Objects is provided by the [[Documentation/{{documentation/version}}/Extensions/Reporting|Reporting extension]]</ref>
|[[Documentation/{{documentation/version}}/Modules/DICOM|DICOM]], [[Documentation/{{documentation/version}}/Modules/DicomToNrrdConverter|DICOMToNRRDConverter]], [[Documentation/{{documentation/version}}/Modules/CreateDICOMSeries|CreateDICOMSeries]], [[Documentation/{{documentation/version}}/Extensions/Reporting|Reporting extension]]
+
|[[Documentation/{{documentation/version}}/Modules/DICOM|DICOM]], [[Documentation/{{documentation/version}}/Modules/DicomToNrrdConverter|DICOMToNRRDConverter]], [[Documentation/{{documentation/version}}/Modules/CreateDICOMSeries|CreateDICOMSeries]], [[Documentation/{{documentation/version}}/Extensions/Reporting|Reporting extension]]. Coordinate system: LPS (specified by the DICOM standard)
 
|-
 
|-
 
| [http://teem.sourceforge.net/nrrd/format.html NRRD]
 
| [http://teem.sourceforge.net/nrrd/format.html NRRD]
Line 40: Line 58:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: as defined in the file header (usually LPS). Segmentation nodes are stored usually with .seg.nrrd extension, as 4D volumes (each 3D volume corresponds to a segment) with some [https://apidocs.slicer.org/master/classvtkMRMLSegmentationStorageNode.html additional custom fields].
 
|-
 
|-
 
| [http://www.itk.org/Wiki/MetaIO/Documentation MetaImage]
 
| [http://www.itk.org/Wiki/MetaIO/Documentation MetaImage]
Line 46: Line 64:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: LPS<ref>According to [http://www.itk.org/Wiki/Proposals:Orientation#Current_ITK_Usage_and_sources_of_confusion MetaIO naming scheme] DICOM 'LPS' direction is 'RAI'.</ref> (AnatomicalOrientation in the file header is ignored)
 
|-
 
|-
 
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK]
 
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK]
Line 52: Line 70:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: LPS
 
|-
 
|-
 
| [http://www.grahamwideman.com/gw/brain/analyze/formatdoc.htm Analyze]
 
| [http://www.grahamwideman.com/gw/brain/analyze/formatdoc.htm Analyze]
Line 126: Line 144:
 
|
 
|
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Models
+
| [http://en.wikipedia.org/wiki/MRC_(file_format) MRC] Electron Density
! scope="col"| [[Documentation/{{documentation/version}}/Modules/Models|Models]]
+
| .mrc, .rec
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
|
 +
|-
 +
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Models
 +
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/Models|Models]]
 
|-
 
|-
 
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK Polygonal Data]
 
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK Polygonal Data]
Line 133: Line 157:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: RAS
 
|-
 
|-
 
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK XML Polygonal Data]
 
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK XML Polygonal Data]
Line 139: Line 163:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: RAS
 +
|-
 +
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK Unstructured Grid Data]
 +
| .vtk
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
| Coordinate system: RAS
 +
|-
 +
| [http://www.vtk.org/VTK/img/file-formats.pdf VTK XML Unstructured Grid Data]
 +
| .vtp
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
| Coordinate system: RAS
 
|-
 
|-
 
| STL
 
| STL
Line 145: Line 181:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: RAS
 
|-
 
|-
 
| OBJ
 
| OBJ
 
| .obj
 
| .obj
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
| Coordinate system: RAS
 +
|-
 +
| Freesurfer
 +
|  .orig, .inflated, .sphere, .white, .smoothwm, .pial
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="#f34a33" align="center"|no
 
|bgcolor="#f34a33" align="center"|no
Line 154: Line 196:
 
|-
 
|-
 
| Others (to be tested)
 
| Others (to be tested)
|  .g, .byu, .orig, .inflated, .sphere, .white, .smoothwm, .pial
+
|  .g, .byu
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="#f34a33" align="center"|no
 
|bgcolor="#f34a33" align="center"|no
 
|
 
|
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Fiducials
+
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Fiducials
! scope="col"| [[Documentation/{{documentation/version}}/Modules/Annotations|Annotations]]
+
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/Markups|Markups]]
 
|-
 
|-
 
| CSV
 
| CSV
Line 166: Line 208:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: RAS
 
|-
 
|-
 
| Text
 
| Text
Line 172: Line 214:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: RAS
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Transforms
+
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"|Rulers
! scope="col"| [[Documentation/{{documentation/version}}/Modules/Transforms|Transforms]]
+
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/Annotations|Annotations]]
 
|-
 
|-
| [http://www.itk.org/ItkSoftwareGuide.pdf Transform]
+
| CSV
| .tfm, .mat
+
| .acsv
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: RAS
 
|-
 
|-
 
| Text
 
| Text
Line 187: Line 229:
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
|
+
| Coordinate system: RAS
 +
|-
 +
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Transforms
 +
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/Transforms|Transforms]]
 +
|-
 +
| [http://www.itk.org/ItkSoftwareGuide.pdf ITK Transform]
 +
| .h5
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
| For linear, b-spline, grid (displacement field), thin-plate spline, and composite transforms. Coordinate system: LPS
 +
|-
 +
| [http://www.itk.org/ItkSoftwareGuide.pdf ITK Transform]
 +
| .tfm, .txt
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
| For linear, b-spline, and thin-plate spline, and composite transforms. Coordinate system: LPS
 +
|-
 +
| [http://www.mathworks.com/help/pdf_doc/matlab/matfile_format.pdf Matlab MAT-File]
 +
| .mat
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
| For linear and b-spline transforms. Coordinate system: LPS
 +
|-
 +
| Displacement field
 +
| .nrrd, .nhdr, .mha, .mhd, .nii, .nii.gz
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
| For grid transform. Coordinate system: LPS
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Transfer Functions
+
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Transfer Functions
! scope="col"| [[Documentation/{{documentation/version}}/Modules/VolumeRendering|Volume Rendering]]
+
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/VolumeRendering|Volume Rendering]]
 
|-
 
|-
 
| Volume Rendering properties
 
| Volume Rendering properties
Line 204: Line 273:
 
|
 
|
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Lookup tables
+
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Lookup tables
! scope="col"| [[Documentation/{{documentation/version}}/Modules/Colors|Colors]]
+
! scope="col" style="border-top: 1px solid grey;"| [[Documentation/{{documentation/version}}/Modules/Colors|Colors]]
 
|-
 
|-
 
| [[Documentation/{{documentation/version}}/Modules/Colors#File_format|Text]]
 
| [[Documentation/{{documentation/version}}/Modules/Colors#File_format|Text]]
Line 213: Line 282:
 
|
 
|
 
|-
 
|-
! scope="col" colspan="4" style="border-bottom: 1px solid grey;"| Double Arrays
+
! scope="col" colspan="4" style="border-bottom: 1px solid grey;border-top: 1px solid grey;"| Double Arrays
!
+
! scope="col" style="border-top: 1px solid grey;"|
 
|-
 
|-
 
| CSV
 
| CSV
| .csv
+
| .mcsv
 +
|bgcolor="LightGreen" align="center"|yes
 +
|bgcolor="LightGreen" align="center"|yes
 +
|
 +
|-
 +
| Text
 +
| .txt
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
 
|bgcolor="LightGreen" align="center"|yes
Line 224: Line 299:
  
 
<references/>
 
<references/>
 +
 +
= What if your data is not supported? =
 +
 +
If you have a file of binary data and you know the data is uncompressed and you know the way it is laid out in memory, then one way to load it in Slicer is to create a .nhdr file that points to the binary file.
 +
 +
A way to get started is to download sample data that is similar to your data (e.g. a CT or MR).  Then save that data in .nhdr format and start editing the file to match your data.
 +
 +
Refer to the [http://teem.sourceforge.net/nrrd NRRD format documentation] to see what the keys mean.
  
 
=References=
 
=References=

Revision as of 17:56, 17 June 2019

Home < Documentation < Nightly < SlicerApplication < SupportedDataFormat


For the latest Slicer documentation, visit the read-the-docs.


File formats supported by Slicer Nightly

Format File Name Extensions Read Write Module
Scenes Data
MRML (Medical Reality Markup Language File) .mrml yes yes MRML file is a xml-formatted text file with scene metadata and pointers to externally stored data files. See Data Model. Coordinate system: RAS
MRB (Medical Reality Bundle) .mrb, .zip yes yes (.mrb extension only) MRB is a binary format encapsulating all scene data (bulk data and metadata). Internally it uses zip format. Any .zip file that contains a self-contained data tree including a .mrml file can be opened. Coordinate system: RAS
Slicer 2 Scene .xml yes no xml-formatted text file with scene metadata and pointers to externally stored data files. Coordinate system: RAS
Data collections in XNAT Catalog format (".xcat") or XNAT Archive format (".xar") .xcat yes no
Data collections in XNAT Archive format (".xar") .xar yes no
Raster Images
this includes 2D and 3D images, and more complicated types such as DWI or DTI
Volumes
DICOM .dcm ... yes[1] yes (some data types)[2] DICOM, DICOMToNRRDConverter, CreateDICOMSeries, Reporting extension. Coordinate system: LPS (specified by the DICOM standard)
NRRD .nrrd, .nhdr yes yes Coordinate system: as defined in the file header (usually LPS). Segmentation nodes are stored usually with .seg.nrrd extension, as 4D volumes (each 3D volume corresponds to a segment) with some additional custom fields.
MetaImage .mhd, .mha yes yes Coordinate system: LPS[3] (AnatomicalOrientation in the file header is ignored)
VTK .vtk yes yes Coordinate system: LPS
Analyze .hdr, .img, .img.gz yes yes
NifTI .nia, .nii, .nii.gz yes yes
BMP .bmp yes yes
BioRad .pic yes yes
Brains2 .mask yes yes
GIPL .gipl .gipl.gz yes yes
JPEG .jpg, .jpeg yes yes
LSM .lsm yes yes
PNG .png yes yes
Stimulate .spr yes yes
TIFF .tif, .tiff yes yes
MGH-NMR .mgz yes yes
MRC Electron Density .mrc, .rec yes yes
Models Models
VTK Polygonal Data .vtk yes yes Coordinate system: RAS
VTK XML Polygonal Data .vtp yes yes Coordinate system: RAS
VTK Unstructured Grid Data .vtk yes yes Coordinate system: RAS
VTK XML Unstructured Grid Data .vtp yes yes Coordinate system: RAS
STL .stl yes yes Coordinate system: RAS
OBJ .obj yes yes Coordinate system: RAS
Freesurfer .orig, .inflated, .sphere, .white, .smoothwm, .pial yes no
Others (to be tested) .g, .byu yes no
Fiducials Markups
CSV .fcsv yes yes Coordinate system: RAS
Text .txt yes yes Coordinate system: RAS
Rulers Annotations
CSV .acsv yes yes Coordinate system: RAS
Text .txt yes yes Coordinate system: RAS
Transforms Transforms
ITK Transform .h5 yes yes For linear, b-spline, grid (displacement field), thin-plate spline, and composite transforms. Coordinate system: LPS
ITK Transform .tfm, .txt yes yes For linear, b-spline, and thin-plate spline, and composite transforms. Coordinate system: LPS
Matlab MAT-File .mat yes yes For linear and b-spline transforms. Coordinate system: LPS
Displacement field .nrrd, .nhdr, .mha, .mhd, .nii, .nii.gz yes yes For grid transform. Coordinate system: LPS
Transfer Functions Volume Rendering
Volume Rendering properties .vp yes yes
Text .txt yes yes
Lookup tables Colors
Text .txt, .ctbl yes yes
Double Arrays
CSV .mcsv yes yes
Text .txt yes yes
  1. For a number of dMRI formats we recommend use of the DICOM to NRRD converter before loading the data into Slicer.
  2. Image volumes, RT structure sets, dose volumes, etc. can be exported using DICOM module's export feature. Limited support for writing image volumes in DICOM format is provided by the Create DICOM Series module. Support of writing DICOM Segmentation Objects is provided by the Reporting extension
  3. According to MetaIO naming scheme DICOM 'LPS' direction is 'RAI'.

What if your data is not supported?

If you have a file of binary data and you know the data is uncompressed and you know the way it is laid out in memory, then one way to load it in Slicer is to create a .nhdr file that points to the binary file.

A way to get started is to download sample data that is similar to your data (e.g. a CT or MR). Then save that data in .nhdr format and start editing the file to match your data.

Refer to the NRRD format documentation to see what the keys mean.

References