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

confusing comment in Gaussian 1D kernel creation #9

Closed
easz opened this issue Dec 23, 2021 · 1 comment
Closed

confusing comment in Gaussian 1D kernel creation #9

easz opened this issue Dec 23, 2021 · 1 comment

Comments

@easz
Copy link

easz commented Dec 23, 2021

# # Since we are calling correlate, not convolve, revert the kernel

# # Since we are calling correlate, not convolve, revert the kernel
# weights = _gaussian_kernel1d(sigma, order, lw)[::-1]
weights = _gaussian_kernel1d(sigma, order, lw)

the kernel is not reverted or do I understand wrong?

@martibosch
Copy link
Owner

martibosch commented Jan 3, 2022

Hello @easz,

this was written a while ago and I do not remember exactly why the kernel was reverted at first, but in the released code the kernel is not reverted (the [::-1] is not in the uncommented line), and it is actually ndi.convolve that is used to build the pixel features with the kernel.

Hope this helps. Best,
Martí

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

No branches or pull requests

2 participants