-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Labels
enhancementNew feature or requestNew feature or request
Description
What would you like to see added in this software?
Type annotation alone do not force errors when instantiating the items (e.g. data instances) without the properties that are required for them to work properly (gradients, etc.). These attributes need to have the default=Nonefield because the base class already has some optional attributes, and no optional attribute can be followed by a mandatory one.
e.g. The following statement does not raise any error, despite gradients being necessary for a DWI instance to work for NiFreeze purposes (although not for the test):
Lines 101 to 105 in adf71da
| data = DWI( | |
| dataobj=rng.normal(size=(*_S0.shape, 10)), | |
| bzero=_clipped_S0, | |
| brainmask=mask, | |
| ) |
Thus, some refactoring is needed to ensure that these properties are present at initialization and the appropriate tests would be required.
Do you have any interest in helping implement the feature?
Yes
Additional information / screenshots
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request