Skip to content

Commit

Permalink
Merge pull request #98 from JuliaRobotics/23Q4/fix/evalvec
Browse files Browse the repository at this point in the history
bug fix eval vector
  • Loading branch information
dehann committed Jan 22, 2024
2 parents 7efdf81 + bb087aa commit c0a707c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/DualTree01.jl
Expand Up @@ -428,21 +428,21 @@ Evaluate the KDE object at given points.
> **Note**, must use Array{Float64,2} when passing in evaluation points.
"""
function (bd::BallTreeDensity)(pos::Array{Float64,2},
function (bd::BallTreeDensity)(pos::AbstractMatrix{Float64},
lvFlag::Bool=false,
errTol::Float64=1e-3,
addop=(+,),
diffop=(-,) )
evaluateDualTree(bd, pos, lvFlag, errTol, addop, diffop)
end
function (bd::BallTreeDensity)(pos::Array{Float64,1},
function (bd::BallTreeDensity)(pos::AbstractVector{Float64},
lvFlag::Bool=false,
errTol::Float64=1e-3,
addop=(+,),
diffop=(-,) )
# TODO should it not be reshape(pos,1,:) instead?
# @warn "whoa! check reshape inside this eval balltree function"
evaluateDualTree(bd, reshape(pos,1,:), lvFlag, errTol, addop, diffop)
evaluateDualTree(bd, reshape(pos,:,1), lvFlag, errTol, addop, diffop)
end


Expand Down

0 comments on commit c0a707c

Please sign in to comment.