Skip to content

ImageFormats

Adrian Quintana edited this page Dec 11, 2017 · 1 revision

Supported Image Formats

Ximpp supports the following image file formats/extensions:

Extension Filetype Read Write Image Volume Stack Data types
raw# Raw files without header info __1__ x
</td>
<td>
  x
</td>
<td>
  x
</td>
<td>
  
</td>
<td>
  All __<sup>2</sup>__
</td>
spi,xmp,vol,stk Spider x x x x x float, cfloat
mrc,map,st,mrcs Medical Research Council __3,4__ x x x x x uint8, (u)int16, float, cfloat
hed/img Imagic x x x
</td>
<td>
  x
</td>
<td>
  uint8, int16, float
</td>
inf/raw Xmipp raw format x x x x
</td>
<td>
  (u)int8, (u)int16, float
</td>
tiff TIFF x x x
</td>
<td>
  x
</td>
<td>
  uint8, uint16, uint32, float
</td>
jpg Jpeg x x x
</td>
<td>
  
</td>
<td>
  uint8
</td>
dm3 Digital Micrograph 3 x
</td>
<td>
  x
</td>
<td>
  
</td>
<td>
  x
</td>
<td>
  int8, (u)int16, (u)int32, float, double
</td>
ser TIA (Tecnai imaging and analysis) x
</td>
<td>
  x
</td>
<td>
  
</td>
<td>
  x
</td>
<td>
  (u)int8, (u)int16, (u)int32, float, double, cfloat, cdouble
</td>
spe Princeton Instrument CCD camera (Win Spec) x
</td>
<td>
  x
</td>
<td>
  
</td>
<td>
  
</td>
<td>
  uint16
</td>
em EM Software Package x
</td>
<td>
  x
</td>
<td>
  x
</td>
<td>
  
</td>
<td>
  int8, int16, int32, float, cfloat, cdouble
</td>
pif Portable Image Format for EM x
</td>
<td>
  x
</td>
<td>
  x
</td>
<td>
  x
</td>
<td>
  int8, int16, int32, float,  cfloat
</td>
hdf,hdf5,h5 Hierarchical Data Format x
</td>
<td>
  x
</td>
<td>
  x
</td>
<td>
  x
</td>
<td>
  All __<sup>2</sup>__
</td>
1 For image files whose format is not supported or you don't have its header file, you can try to read it manually. The way to pass the header info to Xmipp is after the filename in this way:

image.ext#xDim,yDim,[zDim],offset,datatype,[r]

where the parameters are: the pixel dimensions in X, Y axis and optionally Z for volumes, position in bytes where the image data starts and datatype**. By default Xmipp reads in current machine byte order or reverse if r is provided at the end.

2 The bit depth or data type can be: uint8 (uchar), int8 (char), uint16 (ushort), int16 (short), uint32, int32, long, float, double, cint16 (complex int16), cint32 (complex int32), cfloat (complex float), cdouble (complex double) and bool.

3The origin convention between CCP4 and MRC2000 is automaticaly detected as described in http://situs.biomachina.org/fmap.pdf. XMIPP read mrc files following the "unsigned" 8-bit convention (MODE 0) although "signed" 8-bit files can also be read as raw files. First read header info using Image_header_v3, then read the file as described in1 but using int8 as datatype.

4To differentiate as to whether a file represents a cube or 2D planes we use the following convention: The parameter ISPG, represents Space Group Numbers. For 3D volumes of single particle or tomogram entries, ISPG=1 and NSYMBT=0. For image planes ISPG=0 and NSYMBT=0. To manually force an image file to be read as a volume or stack, write the filename with the following suffixes, ":mrc" for volume and:mrcs" for stack. In case ISPG=401 the data is read as a stack of volumes, being the mz field in header the number of volumes in the stack.

Clone this wiki locally