Closed sandrinebedard closed 3 years ago
the function
compute_dice()
could have been written by simply opening the data usingnibabel.load()
and then computing the Dice directly in Python in a two-liner. That way you would have bypassed this issue, your code would probably be 4x shorter and you would remove a system call to SCT (making your open-source code more reusable).i'm approving this anyway because this code has a fairly "isolated" purpose. But useful tips for you to consider in the future.
Oki thanks for the tip!
Description
This PR adds the script
compute_dice.py
that computes dice coefficient across segmentations from candidates and ground truth segmentations as discussed in #36. The script outputs dice coefficient per image for each candidate and mean dice score (saves in log file).Example of output: