|
svo
Semi-Direct Visual Odometry
|
Depth filter implements the Bayesian Update proposed in: "Video-based, Real-Time Multi View Stereo" by G. More...
#include <depth_filter.h>
Classes | |
| struct | Options |
| Depth-filter config parameters. More... | |
Public Types | |
| typedef boost::function< void(Point *, double) | callback_t ) |
Public Member Functions | |
| DepthFilter (feature_detection::DetectorPtr feature_detector, callback_t seed_converged_cb) | |
| virtual | ~DepthFilter () |
| void | startThread () |
| Start this thread when seed updating should be in a parallel thread. | |
| void | stopThread () |
| Stop the parallel thread that is running. | |
| void | addFrame (FramePtr frame) |
| Add frame to the queue to be processed. | |
| void | addKeyframe (FramePtr frame, double depth_mean, double depth_min) |
| Add new keyframe to the queue. | |
| void | removeKeyframe (FramePtr frame) |
| Remove all seeds which are initialized from the specified keyframe. | |
| void | reset () |
| If the map is reset, call this function such that we don't have pointers to old frames. | |
| void | getSeedsCopy (const FramePtr &frame, std::list< Seed > &seeds) |
| Returns a copy of the seeds belonging to frame. | |
| std::list< Seed, aligned_allocator< Seed > > & | getSeeds () |
| Return a reference to the seeds. This is NOT THREAD SAFE! | |
Static Public Member Functions | |
| static void | updateSeed (const float x, const float tau2, Seed *seed) |
| Bayes update of the seed, x is the measurement, tau2 the measurement uncertainty. | |
| static double | computeTau (const SE3 &T_ref_cur, const Vector3d &f, const double z, const double px_error_angle) |
| Compute the uncertainty of the measurement. | |
Public Attributes | |
| EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef boost::unique_lock < boost::mutex > | lock_t |
| struct svo::DepthFilter::Options | options_ |
Protected Member Functions | |
| void | initializeSeeds (FramePtr frame) |
| Initialize new seeds from a frame. | |
| virtual void | updateSeeds (FramePtr frame) |
| Update all seeds with a new measurement frame. | |
| void | clearFrameQueue () |
| When a new keyframe arrives, the frame queue should be cleared. | |
| void | updateSeedsLoop () |
| A thread that is continuously updating the seeds. | |
Protected Attributes | |
| feature_detection::DetectorPtr | feature_detector_ |
| callback_t | seed_converged_cb_ |
| std::list< Seed, aligned_allocator< Seed > > | seeds_ |
| boost::mutex | seeds_mut_ |
| bool | seeds_updating_halt_ |
| Set this value to true when seeds updating should be interrupted. | |
| boost::thread * | thread_ |
| std::queue< FramePtr > | frame_queue_ |
| boost::mutex | frame_queue_mut_ |
| boost::condition_variable | frame_queue_cond_ |
| FramePtr | new_keyframe_ |
| Next keyframe to extract new seeds. | |
| bool | new_keyframe_set_ |
| Do we have a new keyframe to process?. | |
| double | new_keyframe_min_depth_ |
| Minimum depth in the new keyframe. Used for range in new seeds. | |
| double | new_keyframe_mean_depth_ |
| Maximum depth in the new keyframe. Used for range in new seeds. | |
| vk::PerformanceMonitor | permon_ |
| Separate performance monitor since the DepthFilter runs in a parallel thread. | |
| Matcher | matcher_ |
Depth filter implements the Bayesian Update proposed in: "Video-based, Real-Time Multi View Stereo" by G.
Vogiatzis and C. Hernández. In Image and Vision Computing, 29(7):434-441, 2011.
The class uses a callback mechanism such that it can be used also by other algorithms than nslam and for simplified testing.
| typedef boost::function<void ( Point*, double ) svo::DepthFilter::callback_t) |
| svo::DepthFilter::DepthFilter | ( | feature_detection::DetectorPtr | feature_detector, |
| callback_t | seed_converged_cb | ||
| ) |
| virtual svo::DepthFilter::~DepthFilter | ( | ) | [virtual] |
| void svo::DepthFilter::addFrame | ( | FramePtr | frame | ) |
Add frame to the queue to be processed.
| void svo::DepthFilter::addKeyframe | ( | FramePtr | frame, |
| double | depth_mean, | ||
| double | depth_min | ||
| ) |
Add new keyframe to the queue.
| void svo::DepthFilter::clearFrameQueue | ( | ) | [protected] |
When a new keyframe arrives, the frame queue should be cleared.
| static double svo::DepthFilter::computeTau | ( | const SE3 & | T_ref_cur, |
| const Vector3d & | f, | ||
| const double | z, | ||
| const double | px_error_angle | ||
| ) | [static] |
Compute the uncertainty of the measurement.
| std::list<Seed, aligned_allocator<Seed> >& svo::DepthFilter::getSeeds | ( | ) | [inline] |
Return a reference to the seeds. This is NOT THREAD SAFE!
| void svo::DepthFilter::getSeedsCopy | ( | const FramePtr & | frame, |
| std::list< Seed > & | seeds | ||
| ) |
Returns a copy of the seeds belonging to frame.
Thread-safe. Can be used to compute the Next-Best-View in parallel. IMPORTANT! Make sure you hold a valid reference counting pointer to frame so it is not being deleted while you use it.
| void svo::DepthFilter::initializeSeeds | ( | FramePtr | frame | ) | [protected] |
Initialize new seeds from a frame.
| void svo::DepthFilter::removeKeyframe | ( | FramePtr | frame | ) |
Remove all seeds which are initialized from the specified keyframe.
This function is used to make sure that no seeds points to a non-existent frame when a frame is removed from the map.
| void svo::DepthFilter::reset | ( | ) |
If the map is reset, call this function such that we don't have pointers to old frames.
| void svo::DepthFilter::startThread | ( | ) |
Start this thread when seed updating should be in a parallel thread.
| void svo::DepthFilter::stopThread | ( | ) |
Stop the parallel thread that is running.
| static void svo::DepthFilter::updateSeed | ( | const float | x, |
| const float | tau2, | ||
| Seed * | seed | ||
| ) | [static] |
Bayes update of the seed, x is the measurement, tau2 the measurement uncertainty.
| virtual void svo::DepthFilter::updateSeeds | ( | FramePtr | frame | ) | [protected, virtual] |
Update all seeds with a new measurement frame.
| void svo::DepthFilter::updateSeedsLoop | ( | ) | [protected] |
A thread that is continuously updating the seeds.
std::queue<FramePtr> svo::DepthFilter::frame_queue_ [protected] |
boost::condition_variable svo::DepthFilter::frame_queue_cond_ [protected] |
boost::mutex svo::DepthFilter::frame_queue_mut_ [protected] |
| EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef boost::unique_lock<boost::mutex> svo::DepthFilter::lock_t |
Matcher svo::DepthFilter::matcher_ [protected] |
FramePtr svo::DepthFilter::new_keyframe_ [protected] |
Next keyframe to extract new seeds.
double svo::DepthFilter::new_keyframe_mean_depth_ [protected] |
Maximum depth in the new keyframe. Used for range in new seeds.
double svo::DepthFilter::new_keyframe_min_depth_ [protected] |
Minimum depth in the new keyframe. Used for range in new seeds.
bool svo::DepthFilter::new_keyframe_set_ [protected] |
Do we have a new keyframe to process?.
vk::PerformanceMonitor svo::DepthFilter::permon_ [protected] |
Separate performance monitor since the DepthFilter runs in a parallel thread.
callback_t svo::DepthFilter::seed_converged_cb_ [protected] |
std::list<Seed, aligned_allocator<Seed> > svo::DepthFilter::seeds_ [protected] |
boost::mutex svo::DepthFilter::seeds_mut_ [protected] |
bool svo::DepthFilter::seeds_updating_halt_ [protected] |
Set this value to true when seeds updating should be interrupted.
boost::thread* svo::DepthFilter::thread_ [protected] |
1.7.6.1