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
Stacking two or more MultiSampleTrait-like transforms breaks execute_compose() #8528
Describe the bug
If a list of transforms includes more than one MultiSampleTrait-like operations (e.g. each returning a list of generated items), putting this as an argument to execute_compose() will lead to a list of lists being returned by this line of apply_transform. The next transform in the list would then break, because it would try to interpret one entry of the outer list as a single item, e.g. a dict.
To Reproduce
Steps to reproduce the behavior (a sketch):
Expected behavior
Since input list or tuple unwrapping is implemented in apply_transform, and MultiSampleTrait indicates the possibility of such transforms (I know it does not do anything by itself, nor is it used to inform any actions inside MONAI as of now), I expect it to handle return values that are lists or tuples correctly.
Environment
(providing a partial output since the rest seems irrelevant)
Activity
added ReduceTrait and FlattenSequence (#8531)
added ReduceTrait and FlattenSequence (Project-MONAI#8531)
added ReduceTrait and FlattenSequence (Project-MONAI#8531)
added ReduceTrait and FlattenSequence (Project-MONAI#8531)