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

Adds support for specifying kernels using StaticArrays #254

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

zygmuntszpak
Copy link
Member

Fixes #252

@codecov
Copy link

codecov bot commented Dec 5, 2022

Codecov Report

Base: 78.62% // Head: 91.97% // Increases project coverage by +13.34% 🎉

Coverage data is based on head (7e2a965) compared to base (826df52).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff             @@
##           master     #254       +/-   ##
===========================================
+ Coverage   78.62%   91.97%   +13.34%     
===========================================
  Files          12       12               
  Lines        1062     1657      +595     
===========================================
+ Hits          835     1524      +689     
+ Misses        227      133       -94     
Impacted Files Coverage Δ
src/imfilter.jl 92.13% <ø> (+9.96%) ⬆️
src/border.jl 92.46% <100.00%> (+27.83%) ⬆️
src/models.jl 100.00% <0.00%> (ø)
src/kernel.jl 100.00% <0.00%> (+2.24%) ⬆️
src/ImageFiltering.jl 68.75% <0.00%> (+4.46%) ⬆️
src/extrema.jl 100.00% <0.00%> (+5.55%) ⬆️
src/mapwindow.jl 86.45% <0.00%> (+12.84%) ⬆️
src/borderarray.jl 93.33% <0.00%> (+13.67%) ⬆️
src/specialty.jl 100.00% <0.00%> (+15.38%) ⬆️
... and 4 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@zygmuntszpak
Copy link
Member Author

@timholy Please could you take a look when you get a chance

Project.toml Show resolved Hide resolved
@johnnychen94 johnnychen94 self-assigned this Jan 3, 2023
@johnnychen94
Copy link
Member

Sorry I missed this PR and the issue. Will check it ASAP.

hi = last(ind)+last(pad)
interval = 1:length(lo:hi)
T = typeof(T₁)
I = typeof(SOneTo(length(interval)))
Copy link
Member

Choose a reason for hiding this comment

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

This is unfortunately a type-unstable patch: SOneTo{n} where n = length(interval) is runtime information.

IIUC, unless the image itself is also a SMatrix, we can't get a static pad, and thus we can't make it type stable.

The solution to support static array inputs might be converting it back to normal array and unit ranges.

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.

Error When Using SMatrix for FIR Separable Filtration
3 participants