punchbowl.data.io#
Attributes#
Functions#
|
Create a SHA-256 hash for a file. |
|
Determine the base file name without file type extension. |
|
Write an NDCube as a FITS file. |
|
Compress the uncertainty for writing to file. |
|
Uncompress the uncertainty when reading from a file. |
|
|
|
Update image statistics in metadata before writing to file. |
|
Load an NDCube from a FITS file. |
Module Contents#
- punchbowl.data.io._ROOT#
- punchbowl.data.io.write_file_hash(path: str) None#
Create a SHA-256 hash for a file.
- punchbowl.data.io.get_base_file_name(cube: ndcube.NDCube) str#
Determine the base file name without file type extension.
- punchbowl.data.io.write_ndcube_to_fits(cube: ndcube.NDCube, filename: str, overwrite: bool = True, write_hash: bool = True, uncertainty_quantize_level: float = 16) None#
Write an NDCube as a FITS file.
- punchbowl.data.io._pack_uncertainty(cube: ndcube.NDCube) numpy.ndarray#
Compress the uncertainty for writing to file.
- punchbowl.data.io._unpack_uncertainty(uncertainty_array: numpy.ndarray, data_array: numpy.ndarray) numpy.ndarray#
Uncompress the uncertainty when reading from a file.
- punchbowl.data.io._write_ql(cube: ndcube.NDCube, filename: str, overwrite: bool = True) None#
- punchbowl.data.io._update_statistics(cube: ndcube.NDCube) None#
Update image statistics in metadata before writing to file.
- punchbowl.data.io.load_ndcube_from_fits(path: str, key: str = ' ') ndcube.NDCube#
Load an NDCube from a FITS file.