aspire.storage package¶
Submodules¶
aspire.storage.mrc module¶
- class aspire.storage.mrc.MrcStats¶
Bases:
object
Instantiate an empty instance ready to receive slices of arrays.
- Returns:
MrcStats instance
- property amean¶
Compute the curren mean.
- property arms¶
Compute the current standard deviation.
We use the simplest method.
- push(array_slice)¶
Incrementally add contribution of array_slice to stats.
- Parameters:
array_slice – An ndarray to contribute to stats.
- update_header(mrcobj)¶
Assign the statistics to mrcobj header.
- Parameters:
mrcobj – The mrcfile instance we want stats written to.
aspire.storage.starfile module¶
- class aspire.storage.starfile.StarFile(filepath='', blocks=None)¶
Bases:
object
Initialize either from a path to a STAR file or from an OrderedDict of ndarrays
- get_block_by_index(index)¶
Retrieve a dict representing a star file block by its position in the starfile
- write(filepath)¶
Converts blocks to a gemmi Document and writes to a starfile at the given filepath.
- exception aspire.storage.starfile.StarFileError¶
Bases:
Exception