+
Skip to content

Conversation

coreylowman
Copy link
Owner

Resolves #677

@coreylowman
Copy link
Owner Author

@nkoppel for some reason this seems to resolve the bug? I have no idea why. On main I get an illegal memory address accessed. But not on this branch

@nkoppel
Copy link
Contributor

nkoppel commented Apr 8, 2023

This seems to fix it on my end as well, though I am somewhat skeptical that it's not due to a different allocation pattern.

Comment on lines +99 to +102
size_t y0 = min(static_cast<size_t>(h_scale * oh), op.h_in - 1);
size_t y1 = min(y0 + 1, op.h_in - 1);
size_t x0 = min(static_cast<size_t>(w_scale * ow), op.w_in - 1);
size_t x1 = min(x0 + 1, op.w_in - 1);
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nkoppel this was the issue

@coreylowman coreylowman merged commit 07aef2d into main Apr 8, 2023
@coreylowman coreylowman deleted the simplify-upscale branch April 8, 2023 19:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Upscale2D or Conv2D produces NaN values

2 participants

点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载