segmentation_models_pytorch model cant travel to utils folder #796
Unanswered
supratimpaul13
asked this question in
Q&A
Replies: 1 comment
-
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
-
#782 This is the code in example folder for car segmentations.
loss = smp.utils.losses.DiceLoss()
metrics = [
smp.utils.metrics.IoU(threshold=0.5),
]
optimizer = torch.optim.Adam([
dict(params=model.parameters(), lr=0.0001),
])
and it is giving me error:
ModuleNotFoundError Traceback (most recent call last)
Cell In[92], line 4
1 # Dice/F1 score - https://en.wikipedia.org/wiki/S%C3%B8rensen%E2%80%93Dice_coefficient
2 # IoU/Jaccard score - https://en.wikipedia.org/wiki/Jaccard_index
----> 4 import segmentation_models_pytorch.utils.losses as smp_losses
5 import segmentation_models_pytorch.utils.metrics as smp_metrics
7 loss = smp_losses.DiceLoss()
ModuleNotFoundError: No module named 'segmentation_models_pytorch.utils'
I have installed all the necessary libraries required but cant find any solution
Beta Was this translation helpful? Give feedback.
All reactions