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

fixes for open cv features #24

Merged
merged 2 commits into from
Feb 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 21 additions & 3 deletions ext/PyCaesarImagesExt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,18 @@ using ProgressMeter
using JSON3
using TensorCast
using SHA: sha256
using Caesar
using DocStringExtensions

import PyCaesar: calcFlow, getPose, goodFeaturesToTrack, goodFeaturesToTrackORB, combinePlot
import PyCaesar: calcFlow, goodFeaturesToTrack, goodFeaturesToTrackORB, combinePlot
import PyCaesar: trackFeaturesFrames, trackFeaturesForwardsBackwards
import PyCaesar: makeBlobFeatureTracksPerImage_FwdBck!, makeORBParams
import PyCaesar: pycv
import PyCaesar: getPoseEssential, getPoseFundamental
import PyCaesar: getPose # deprecating
import PyCaesar: getPoseSIFT # deprecating

export calcFlow, getPose, goodFeaturesToTrack, goodFeaturesToTrackORB, combinePlot
export calcFlow, getPoseEssential, goodFeaturesToTrack, goodFeaturesToTrackORB, combinePlot
export trackFeaturesFrames, trackFeaturesForwardsBackwards, makeBlobFeatureTracksPerImage_FwdBck!, makeORBParams

pyutilpath = joinpath(@__DIR__, "Utils")
Expand All @@ -25,16 +31,28 @@ const cv = PyNULL()
# const SscPy = PyNULL()
SscPy = pyimport("PySSCFeatures")

# reset the pointers between precompile and using
function __init__()
copy!(np, pyimport("numpy"))
copy!(cv, pyimport("cv2"))
# copy!(SscPy, pyimport("PySSCFeatures"))
end

"""
$SIGNATURES

ssc = SscPy."ssc"
Function to expose the modules internal cv pointer.
"""
pycv() = cv

pyssc = SscPy."ssc"


include("services/OpenCVFeatures.jl")


# deprecation
@deprecate getPose(p1, p2, K) getPoseEssential(p1, p2, K)


end
Loading
Loading