Replies: 1 comment
-
|
Hi @bintadkr, Generally, the selection of transformations in MONAI typically varies greatly depending on the specific task at hand. Although I can't pinpoint the issue directly from you code, I recommend diligently reviewing the output of each transformation. BTW, it's noteworthy that the image seems almost separable by a simple thresholding. Hope it helps. |
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,
I'm trying to segment zebrafish embryos with MONAI, but this is what I get. I think the main problem is how I transform the data.
What tranforms do you think I can use to fix this?
These are the tranforms I currently have:
train_transforms = Compose(
[
LoadImaged(keys=["vol", "seg"]),
EnsureChannelFirstD(keys=["vol", "seg"]),
Spacingd(keys=["vol", "seg"], pixdim=pixdim, mode=("bilinear", "nearest")),
Orientationd(keys=["vol", "seg"], axcodes="RAS"),
ScaleIntensityRanged(keys=["vol"], a_min=a_min, a_max=a_max, b_min=0.0, b_max=1.0, clip=True),
CropForegroundd(keys=["vol", "seg"], source_key="vol"),
Resized(keys=["vol", "seg"], spatial_size=spatial_size),
ToTensord(keys=["vol", "seg"]),
]
)
val_transforms = Compose(
[
LoadImaged(keys=["vol", "seg"]),
EnsureChannelFirstD(keys=["vol", "seg"]),
Spacingd(keys=["vol", "seg"], pixdim=pixdim, mode=("bilinear", "nearest")),
Orientationd(keys=["vol", "seg"], axcodes="RAS"),
ScaleIntensityRanged(keys=["vol"], a_min=a_min, a_max=a_max, b_min=0.0, b_max=1.0, clip=True),
CropForegroundd(keys=['vol', 'seg'], source_key='vol'),
Resized(keys=["vol", "seg"], spatial_size=spatial_size),
ToTensord(keys=["vol", "seg"]),
]
)
This is the results I have:

Beta Was this translation helpful? Give feedback.
All reactions