You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My understanding of the SpatialImage API is that image.affine is authoritative, and that it is written into the header prior to writing to file. This can lead to surprises for users modifying header attributes that correspond to the affine. For example, zooms may be used to construct an affine (MGHImage/NIfTI with no valid sform) or be unrelated (see #619 for further discussion).
image.update_header() is called at image construction and writing. I would suggest that we warn if it causes changes to the header at write time. (At construction time might occasionally be useful, but it will cause a lot of noise.)
My understanding of the
SpatialImage
API is thatimage.affine
is authoritative, and that it is written into the header prior to writing to file. This can lead to surprises for users modifying header attributes that correspond to the affine. For example, zooms may be used to construct an affine (MGHImage/NIfTI with no valid sform) or be unrelated (see #619 for further discussion).image.update_header()
is called at image construction and writing. I would suggest that we warn if it causes changes to the header at write time. (At construction time might occasionally be useful, but it will cause a lot of noise.)Sub-issue identified in #619.
Related: #668
The text was updated successfully, but these errors were encountered: