scHopfield.tools.save_jacobians
- scHopfield.tools.save_jacobians(adata: AnnData, filename: str, cluster_key: str = 'cell_type', compression: str = 'gzip')[source]
Save Jacobian eigenvalues and eigenvectors to HDF5 file.
Saves eigenvalues and eigenvectors (if computed) to an HDF5 file with compression. Complex arrays are stored as separate real and imaginary parts. Removes temporary eigenvector storage from adata after saving.
- Parameters:
adata (AnnData) – Annotated data object with computed Jacobian data
filename (str) – Path to save HDF5 file
cluster_key (str, optional (default: 'cell_type')) – Cluster key to store as metadata attribute
compression (str, optional (default: 'gzip')) – HDF5 compression algorithm (‘gzip’, ‘lzf’, etc.)