Repository navigation
Breaking release. The API is renamed to follow the standard, and the header now checks what it is given.
Breaking
- Renamed:
SdfDialect→Revision,SdfHeader→Header,SdfMetadata→Metadata,with_dialect→with_revision,--dialect→--revision. Header.binaryis replaced byHeader.format.num_pointsandnum_profilesare gone; usesdf.data.shape.SdfFile.data_typeandSdfFile.openare removed; useheader.data_typeandsdfio.read.- A
Headerrejects an unsupported data type, a non-positivez_scaleand a non-ASCIImanufacturer_id. z_scalenow defaults to"auto", andMetadatadates default to"now".Nonemeans "not recorded".SdfFormatErroris also aValueError.- Codec helpers such as
encode_rawandget_data_typeare no longer in the top-level API.
New
SdfFile.from_arrayandSdfFile.with_data.with_revision(..., refit_z_scale=True).Revision.rules, for examplemax_binary_count.- Four examples:
write,read,modifyandplot.
Changed
- Dates are held as UTC. Older revisions still store local time on disk.
- Reading tolerates a byte order mark and
NaNasBAD.
Fixed
- A truncated or oversized binary header now raises
SdfFormatErrorinstead ofstruct.errororOverflowError.