Christopher Tensmeyer
Christopher Tensmeyer
I have an idea on how kernel weights might be set in the code. You have a note on the README asking for explanations. In the 2011 paper (Eq. 2),...
I downloaded the data from the google drive link, and several image files are empty (0 bytes), including: ./train/img/1807.04686v1.1.png ./train/img/1610.02534v1.3.png ./train/img/0804.1441v3.3.png ./train/img/1611.02944v1.9.png ./train/img/1712.01039v2.4.png ./train/img/1705.03385v1.2.png ./train/img/1702.00552v1.1.png ./train/img/0705.1956v1.13.png ./train/img/1803.01529v1.3.png ./train/img/1703.09695v1.1.png ./train/img/1803.04786v1.4.png ./train/img/1402.1107v1.1.png...
``` ce_loss = F.cross_entropy(input, target,reduction=self.reduction,weight=self.weight) pt = torch.exp(-ce_loss) focal_loss = ((1 - pt) ** self.gamma * ce_loss).mean() ``` While `ce_loss` is correctly `-weight[y_t]log(p[y_t])`, `pt` is not `p[y_t]` as you would...