Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Libnd4j: conv2d op: switch to single weights format #6393

AlexDBlack opened this issue Sep 7, 2018 · 1 comment


Copy link

commented Sep 7, 2018

Following on from the discussion in slack: Our libnd4j conv2d op weights format depend on the activations input format (NCHW vs. NHWC).

However, for TF import, we require weights in [kH, kW, inC, outC] for both cases.
In principle, we could transpose weights on import - but after considering this, it seems too brittle (too many edge cases).

Instead, let's change the weights format for conv2d to always be [kH, kW, inC, outC] regardles of the input format.

Note DL4J uses [outC, inC, kH, kW] but we'll handle that at the Java/DL4J level via permute when we use conv2d op.
There's also the question of performance vs. weight layout, but let's leave that question for another time, as that will require extensive testing.


This comment has been minimized.

Copy link

commented Oct 12, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Oct 12, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
2 participants
You can’t perform that action at this time.