Doubt about future phases (and bugs found - which are not being caught by tests) #134
Closed
Devguru-codes
started this conversation in
General
Replies: 1 comment
-
|
Also we should add that in tests. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello @ltorres6 sir, I just wanted to know if I can contribute and help with the completion of phase 3. I can contribute in its completion.

Also when I was traversing the project and seeing the phase 3 tasks - I have found 2 bugs.
Bug 1 - Missing affine in _compute_t1_map() - osipy\pipeline\dce_pipeline.py (line 278)
we need affine here because when a user calls DCEPipeline.run() with a raw numpy array for t1_data instead of a pre-built PerfusionDataset it will raise an TypeError: PerfusionDataset.init() missing 1 required positional argument: 'affine'.The population AIF path is unaffected here.
What is needed - if we add just a line - affine=np.eye(4) - this will fix the bug completely.
Code to reproduce the bug -
Proof - terminal screenshot -

Bug 2 - Wrong kwarg time and need affine in _get_aif()- osipy\pipeline\dce_pipeline.py (lines 308 to 312)
time is not a valid field. PerfusionDataset dataclass has field name is time_points.
affine is also required here
why is the issue not caught - when a user configures aif_source: detect in their YAML config (to auto-detect AIF from data). The default aif_source: population is unaffected, which is why tests pass - no test exercises this exact code path.
What to change - Change time=time to time_points=time and add affine=np.eye(4).
Code to reproduce the bug -
Proof - ss from terminal -

@ltorres6 sir, I want to discuss about the issues before I create the issue and submit the fix for it. Also wanted to contribute in phase 3. Thank you sir.
Beta Was this translation helpful? Give feedback.
All reactions