pyunitwizard.storage.asdf.read#

pyunitwizard.storage.asdf.read(path, **expectations)[source]#

Verify one complete local ASDF file and detach its quantity snapshot.

Parameters:
  • path (path-like) – Local complete file, with no remote/archive or partial-read interface.

  • **expectations – Explicit receiver handshake accepted by from_tree.

Returns:

Verified snapshot, surviving closure of the native ASDF file.

Return type:

QuantityRecord

Raises:
  • RecordError – For unreadable/corrupt input, missing extensions or binding disagreement.

  • ModuleNotFoundError – If an optional provider is absent.

Examples

>>> restored = read('proper_motion.asdf', unit='radian / second')