fabio.openimage
index
/usr/lib/pymodules/python2.6/fabio/openimage.py

Authors: Henning O. Sorensen & Erik Knudsen
         Center for Fundamental Research: Metal Structures in Four Dimensions
         Risoe National Laboratory
         Frederiksborgvej 399
         DK-4000 Roskilde
         email:henning.sorensen@risoe.dk
 
mods for fabio by JPW

 
Modules
       
fabio.GEimage
fabio.HiPiCimage
fabio.OXDimage
fabio.adscimage
fabio.bruker100image
fabio.brukerimage
fabio.cbfimage
fabio.dm3image
fabio.edfimage
fabio
fabio.fit2dmaskimage
fabio.fit2dspreadsheetimage
fabio.kcdimage
fabio.mar345image
fabio.marccdimage
fabio.pilatusimage
fabio.pnmimage
fabio.tifimage

 
Functions
       
do_magic(byts)
Try to interpret the bytes starting the file as a magic number
openheader(filename)
return only the header
openimage(filename)
Try to open an image

 
Data
        MAGIC_NUMBERS = [('FORMAT : 86', 'bruker'), ('MM\x00*', 'tif'), ('II*\x00\x08\x00', 'marccd'), ('II*\x00\x82\x00', 'pilatus'), ('II*\x00', 'tif'), ('{\nHEA', 'adsc'), ('{', 'edf'), ('\r{', 'edf'), ('\n{', 'edf'), ('ADEPT', 'GE'), ('OD', 'OXD'), ('IM', 'HiPiC'), ('-\x04', 'mar345'), ('\x04-', 'mar345'), ('M\x00\x00\x00A\x00\x00\x00S\x00\x00\x00K\x00\x00\x00', 'fit2dmask'), ('\x00\x00\x00\x03', 'dm3'), ('No', 'kcd')]