diff options
author | Keir Mierle <mierle@gmail.com> | 2012-09-20 02:01:42 +0400 |
---|---|---|
committer | Keir Mierle <mierle@gmail.com> | 2012-09-20 02:01:42 +0400 |
commit | 8a46b8454ed1788c1ac17d36187e79c8a4cbb10d (patch) | |
tree | 4f3c0f628c83e76af59ad33b016bca3b13aee1c9 | |
parent | a09b5c1f2036333608276674d4a6047b911556ed (diff) |
Cleanup for when trackers fall out of the search window.
Sergey originally left a TODO() here, but his fix is the correct
one. I removed the TODO and fixed some comment issues.
-rw-r--r-- | extern/libmv/libmv/tracking/track_region.cc | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/extern/libmv/libmv/tracking/track_region.cc b/extern/libmv/libmv/tracking/track_region.cc index 8973a8d0148..89f18afd556 100644 --- a/extern/libmv/libmv/tracking/track_region.cc +++ b/extern/libmv/libmv/tracking/track_region.cc @@ -18,7 +18,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS // IN THE SOFTWARE. // -// Author: mierle@google.com (Keir Mierle) +// Author: mierle@gmail.com (Keir Mierle) // // TODO(keir): While this tracking code works rather well, it has some // outragous inefficiencies. There is probably a 5-10x speedup to be had if a @@ -41,7 +41,11 @@ #include "libmv/multiview/homography.h" #include "libmv/numeric/numeric.h" +// Expand the Jet functionality of Ceres to allow mixed numeric/autodiff. +// +// TODO(keir): Push this (or something similar) into upstream Ceres. namespace ceres { + // A jet traits class to make it easier to work with mixed auto / numeric diff. template<typename T> struct JetOps { @@ -113,7 +117,8 @@ struct Chain<FunctionType, kNumArgs, Jet<T, N> > { return jet_f; } }; -} + +} // namespace ceres namespace libmv { @@ -1364,12 +1369,6 @@ void TemplatedTrackRegion(const FloatImage &image1, // TODO(keir): Update the result statistics. // TODO(keir): Add a normalize-cross-correlation variant. - // TODO(sergey): in previous bundled Ceres from Windows branch our callback - // wasn't called, so USER_ABORT was never happen. - // now callback is calling and in some cases it returns SOLVER_ABORT - // not sure if it's bug somewhere or we could just mark tracking - // result as failed without causing general panic - // CHECK_NE(summary.termination_type, ceres::USER_ABORT) << "Libmv bug."; if (summary.termination_type == ceres::USER_ABORT) { result->termination = TrackRegionResult::FELL_OUT_OF_BOUNDS; return; |