Skip to content

Commit

Permalink
Merge pull request #28 from lucianolorenti/julia_1.0
Browse files Browse the repository at this point in the history
changes for precompilation in Julia 1.0
  • Loading branch information
timholy authored Sep 28, 2018
2 parents c0fbc88 + 98ff028 commit 6d23970
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/meanshift.jl
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Parameters:
- iter/eps = stopping criterion for meanshift procedure. The algorithm stops after iter iterations or if kernel center moves less than eps distance in an update step, whichever comes first.
"""

function meanshift{CT}(img::Array{CT, 2}, spatial_radius::Real, range_radius::Real; iter::Int = 50, eps::Real = 0.01)
function meanshift(img::Array{CT, 2}, spatial_radius::Real, range_radius::Real; iter::Int = 50, eps::Real = 0.01) where CT

rows, cols = size(img)
rowbins = Int(floor(rows/spatial_radius))
Expand Down Expand Up @@ -88,4 +88,4 @@ function meanshift{CT}(img::Array{CT, 2}, spatial_radius::Real, range_radius::Re
end

return SegmentedImage(result, labels, region_means, region_pix_count)
end
end
2 changes: 1 addition & 1 deletion src/region_growing.jl
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ end
function seeded_region_growing(img::AbstractArray{CT,N}, seeds::AbstractVector{Tuple{CartesianIndex{N},Int}},
neighbourhood::Function, diff_fn::Function = default_diff_fn) where {CT<:Colorant, N}

const _QUEUE_SZ = 10
_QUEUE_SZ = 10

# Check if labels are positive integers
for seed in seeds
Expand Down

0 comments on commit 6d23970

Please sign in to comment.