We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
mode="reflect"
I think mode="reflect" for padding_kwargs is incorrect:
padding_kwargs
import jax.numpy as jnp import kernex @kernex.kmap( kernel_size=(3,), padding=("same"), relative=False, padding_kwargs=dict(mode="reflect"), ) def f(x): return x x = jnp.array([1, 2, 3, 4, 5]) y = f(x) z = jnp.pad(x, 1, mode="reflect") print("x: ", x) print("y: ", y) print("z: ", z)
gives
x: [1 2 3 4 5] y: [[3 1 2] # <-- the `3` is incorrect, should be `2` [1 2 3] [2 3 4] [3 4 5] [4 5 4]] z: [2 1 2 3 4 5 4] # <-- here, the first element is `2`
The Kernex output reflects incorrectly: the first element is 3 instead of 2.
3
2
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I think
mode="reflect"
forpadding_kwargs
is incorrect:gives
The Kernex output reflects incorrectly: the first element is
3
instead of2
.The text was updated successfully, but these errors were encountered: