Open lirundong opened 5 years ago
Updated review:
I compared this reimplementation with the official implementation, there are some differences:
DigitNet_Q
is not consistent with the origin paper: the building blocks should be in Conv -> BN -> [MaxPool] -> ReLU (clip 0, 1) -> QuantAct
order as here, rather than Conv -> BN -> ReLU -> MaxPool -> Clip 0, 1 -> QuantAct
in your implementation;exponential_decay
doc for the underlaying scheme. Please try to fix these issues and try again.
I do think this repository is an elegant and faithful reimplementation of the DoReFa paper. Belowing are some minor concerns to me:
There is a minor mistake in gradient quantizer implementation. Please note the equation 12 in origin paper, the absolute magnitude is taken from each instance within the minibatch:
so you can pass
dim=0
option totorch.max
. Be aware of the return values whendim
is assigned;.gitignore
to filter out the.DS_Store
and__pycache__
files. They are not meant to tracked by git.After all, very very excellent work. Once you done the numeracal camparison, we can have some conversations and go for broader directions.