1 lightning.finite_horizon.resume
lightning.finite_horizon.resume
Verified epoch-boundary recovery for diagnostic Q_H fits.
The immutable diagnostic publication remains owned by aria_nbv.lightning.finite_horizon.experiment. This module owns the smaller mutable seam used while a fit is active: one last-good checkpoint per completed training epoch and a content-bound reference that can reopen it.
1.1 Classes
| Name | Description |
|---|---|
| QhDiagnosticResumeRef | Content-bound full Lightning checkpoint for one compatible fit. |
1.1.1 QhDiagnosticResumeRef
lightning.finite_horizon.resume.QhDiagnosticResumeRef(
checkpoint_path,
checkpoint_sha256,
execution_identity_sha256,
)Content-bound full Lightning checkpoint for one compatible fit.
1.1.1.1 Attributes
| Name | Type | Description |
|---|---|---|
| checkpoint_path | Path | Trusted local full-state Lightning checkpoint. |
| checkpoint_sha256 | str | SHA-256 of the exact checkpoint bytes. |
| execution_identity_sha256 | str | Fit identity embedded by the checkpoint’s originating experiment. The receiving fit independently recomputes this identity before asking Lightning to restore any state. |
1.1.1.2 Methods
| Name | Description |
|---|---|
| from_checkpoint | Build a verified reference from a trusted local checkpoint. |
1.1.1.2.1 from_checkpoint
lightning.finite_horizon.resume.QhDiagnosticResumeRef.from_checkpoint(
checkpoint_path,
)Build a verified reference from a trusted local checkpoint.
1.2 Functions
| Name | Description |
|---|---|
| load_trusted_qh_resume_checkpoint | Deserialize a provenance-verified local checkpoint for validation. |
| validate_qh_resume_checkpoint_payload | Validate one already trusted full-state Lightning checkpoint payload. |
1.2.1 load_trusted_qh_resume_checkpoint
lightning.finite_horizon.resume.load_trusted_qh_resume_checkpoint(path)Deserialize a provenance-verified local checkpoint for validation.
Resume checkpoints contain Python and NumPy RNG tuples, which cannot be reconstructed by weights_only=True. Callers must establish trusted local provenance and an expected SHA-256 before crossing this pickle boundary. This function validates structure after deserialization; it does not make an untrusted pickle safe.
1.2.2 validate_qh_resume_checkpoint_payload
lightning.finite_horizon.resume.validate_qh_resume_checkpoint_payload(payload)Validate one already trusted full-state Lightning checkpoint payload.