RPIN
RPIN copied to clipboard
fix wrongly printed seq_loss
why is it wrong?
If you would like a batch stat (the same as p1, p2, s1, s2, m1, m2), it should have been =
If you would like the overall stat (the same as accuracy for bg and fg), an AverageMeter is usually needed
Simply adding loss could ends up with terrifying resules
I want overall stat. p1, p2, s1, s2, m1, m2 are also overall stat. https://github.com/HaozhiQi/RPIN/blob/master/rpin/trainer.py#L176-L180
Is there any difference between the current implementation and AverageMeter? It looks like the AverageMeter also simply adding losses. Is there anything I missed?
I want overall stat. p1, p2, s1, s2, m1, m2 are also overall stat. https://github.com/HaozhiQi/RPIN/blob/master/rpin/trainer.py#L176-L180
Is there any difference between the current implementation and AverageMeter? It looks like the AverageMeter also simply adding losses. Is there anything I missed?
The key of average meter is to divide current value by batch_size
. The accuracy part is correct, as batch_size is in both denominator (xg_sum) and numerator (xg_correct).
Also.... Since it's a binary classification problem, can I ask why accuracy on both tp and fn are used instead of metrics like auroc, auprc, f1?
I want overall stat. p1, p2, s1, s2, m1, m2 are also overall stat. https://github.com/HaozhiQi/RPIN/blob/master/rpin/trainer.py#L176-L180 Is there any difference between the current implementation and AverageMeter? It looks like the AverageMeter also simply adding losses. Is there anything I missed?
The key of average meter is to divide current value by
batch_size
. The accuracy part is correct, as batch_size is in both denominator (xg_sum) and numerator (xg_correct).
Sorry I still can't understand it. The average meter divides the (sum loss) by the (sum batch size) of a few iterations, which is what I did (see sum of loss, sum of batch size), and sum of loss divides sum of batch size.
Also.... Since it's a binary classification problem, can I ask why accuracy on both tp and fn are used instead of metrics like auroc, auprc, f1?
There is no particular reason of using accuracy v.s. other metrics. This is just used for monitoring the training. The actual evaluation protocal (reported in paper) is followed by the PHYRE benchmark, and evaluation during training my just be very slow.
i'll close this since it's inactive for 3 months. feel free to reopen if needed.