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
{{ message }}
Repository navigation
StdShiftIntensity does redundant full-image mask + gather + scatter on the default nonzero=False path #8972
StdShiftIntensity._stdshift (monai/transforms/intensity/array.py) always builds a full-image boolean mask, gathers every voxel through it, computes the std on that copy, and scatters back:
On the default nonzero=False path (also the default for RandStdShiftIntensity), slices is all-True, so std(img[slices]) == std(img) and the scatter is just img + offset. The mask allocation, .any(), gather and scatter are extra.
Activity
Perf: skip redundant full-image mask on StdShiftIntensity nonzero=Fal…