ServiceNow / HighRes-net

Pytorch implementation of HighRes-net, a neural network for multi-frame super-resolution, trained and tested on the European Space Agency’s Kelvin competition. This is a ServiceNow Research project that was started at Element AI.
https://www.elementai.com/news/2019/computer-enhance-please
Other
277 stars 51 forks source link

Use torch.div #11

Open smermet opened 2 years ago

smermet commented 2 years ago

Prevent a UserWarning :

/HighRes-net/src/lanczos.py:39: UserWarning: floordiv is deprecated, and its behavior will change in a future version of pytorch. It currently rounds toward 0 (like the 'trunc' function NOT 'floor'). This results in incorrect rounding for negative values. To keep the current behavior, use torch.div(a, b, rounding_mode='trunc'), or for actual floor division, use torch.div(a, b, rounding_mode='floor'). Z = (N - S) // 2 # width of zeros beyond kernel support