sacmehta / YNet

Y-Net: Joint Segmentation and Classification for Diagnosis of Breast Biopsy Images
https://sacmehta.github.io/YNet/
MIT License
135 stars 33 forks source link

"instance-level probability map" generation code #3

Closed monjoybme closed 5 years ago

monjoybme commented 5 years ago

I'm working on your YNet architecture. Could you please share the code for instance-level probability map generation? In the recent repository, only instance-level segmentation mask generation code is available but no instance-level probability map code. Thanks in advance.

sacmehta commented 5 years ago

If you look at stage2, the models generate two outputs, one for segmentation and other for classification. From the output of classification branch, you can compute probability by first applying softmax and then pick the maximum probability value. To have instance probability map, you can create a tensor with the same size as input and then fill it with the probability that you computed earlier.

Hope this helps!

monjoybme commented 5 years ago

Thanks!

haiqinzhong commented 3 years ago

@monjoybme , hey, did you remember how to get the instance probability map? I don't know how to fill it to a tensor

monjoybme commented 3 years ago

Please check the answer discussed above.

haiqinzhong commented 3 years ago

Yes, I have checked. But I don't know how to fill the tensor with the probability while the output size of classification branch just [1, 5]