fabio.cbfimage.cbfimage

Package fabio :: Module cbfimage :: Class cbfimage |
[hide private]
[frames] | no frames]

# Class cbfimage

source code

               object --+
                        |
    fabioimage.fabioimage --+
                            |
                           cbfimage

Read the Cif Binary File data format

Instance Methods | [hide private]
__init__(self, data=None, header=None, fname=None) Constructor of the class CIF Binary File reader. | source code
_readheader(self, inStream) Read in a header in some CBF format from a string representing binary stuff | source code
read(self, fname, frame=None) Read in header into self.header and... | source code
numpy array |
_readbinary_byte_offset(self, inStream) Read in a binary part of an x-CBF_BYTE_OFFSET compressed image | source code
write(self, fname) write the file in CBF format | source code
Inherited from `fabioimage.fabioimage`: `add`, `convert`, `getclassname`, `getframe`, `getheader`, `getmax`, `getmean`, `getmin`, `getstddev`, `integrate_area`, `load`, `make_slice`, `next`, `previous`, `readROI`, `readheader`, `rebin`, `resetvals`, `save`, `toPIL16`, `update_header` Inherited from `fabioimage.fabioimage` (private): `_compressed_stream`, `_open` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__sizeof__`, `__str__`, `__subclasshook__`

Static Methods | [hide private]
checkData(data=None) Empty for fabioimage but may be populated by others classes, especially for format accepting only integers | source code
Inherited from `fabioimage.fabioimage`: `checkHeader`

Class Variables | [hide private]
Inherited from `fabioimage.fabioimage` (private): `_need_a_real_file`, `_need_a_seek_to_read`

Properties | [hide private]
Inherited from `fabioimage.fabioimage`: `classname` Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, data=None, header=None, fname=None) (Constructor) | source code
Constructor of the class CIF Binary File reader. Parameters: `_strFilename` (string) - the name of the file to open Overrides: object.__init__

### checkData(data=None) Static Method | source code
Empty for fabioimage but may be populated by others classes, especially for format accepting only integers Overrides: fabioimage.fabioimage.checkData (inherited documentation)

### _readheader(self, inStream) | source code
Read in a header in some CBF format from a string representing binary stuff Parameters: `inStream` (opened file.) - file containing the Cif Binary part. Overrides: fabioimage.fabioimage._readheader

### read(self, fname, frame=None) | source code
    Read in header into self.header and
        the data   into self.data
Overrides: fabioimage.fabioimage.read

### _readbinary_byte_offset(self, inStream) | source code
Read in a binary part of an x-CBF_BYTE_OFFSET compressed image Parameters: `inStream` (python string.) - the binary image (without any CIF decorators) Returns: numpy array a linear numpy array without shape and dtype set

### write(self, fname) | source code
write the file in CBF format Parameters: `fname` - name of the file Overrides: fabioimage.fabioimage.write