Skip to content

Commit

Permalink
Fix/18.04 (#241)
Browse files Browse the repository at this point in the history
* switch to PIL library for Image

* deactivate threading for cv image displays

* Update MulticamGraph.py

Preserve some backward compatibility with older python versions.

* fix opencv windows

* add option to manually input forcal length

* remove debug option

* PR review @LBern

* switch to double in the first place

* Revert "Merge pull request #304 from ethz-asl/feature/input_focal_length_guess"

This reverts commit 2999e18, reversing
changes made to ee2b09d.

Co-authored-by: Hannes Sommer <hannes.sommer@enlightware.ch>
  • Loading branch information
floriantschopp and HannesSommer authored Feb 3, 2020
1 parent 8fbb27d commit cb6fb66
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 8 deletions.
3 changes: 1 addition & 2 deletions aslam_cv/aslam_cameras/src/GridDetector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@ GridDetector::GridDetector(boost::shared_ptr<CameraGeometryBase> geometry,
void GridDetector::initializeDetector()
{
if (_options.plotCornerReprojection) {
cv::namedWindow("Corner reprojection");
cvStartWindowThread();
cv::namedWindow("Corner reprojection", cv::WINDOW_NORMAL);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,8 @@ GridCalibrationTargetAprilgrid::GridCalibrationTargetAprilgrid() :
void GridCalibrationTargetAprilgrid::initialize()
{
if (_options.showExtractionVideo) {
cv::namedWindow("Aprilgrid: Tag detection");
cv::namedWindow("Aprilgrid: Tag corners");
cvStartWindowThread();
cv::namedWindow("Aprilgrid: Tag detection", cv::WINDOW_NORMAL);
cv::namedWindow("Aprilgrid: Tag corners", cv::WINDOW_NORMAL);
}

//create the tag detector
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -598,8 +598,11 @@ def printParameters(cself, dest=sys.stdout):
corners, reprojs, rerrs = getReprojectionErrors(cself, cidx)
if len(rerrs)>0:
me, se = getReprojectionErrorStatistics(rerrs)
print >> dest, "\t reprojection error: [%f, %f] +- [%f, %f]" % (me[0], me[1], se[0], se[1])
print >> dest
try:
print >> dest, "\t reprojection error: [%f, %f] +- [%f, %f]" % (me[0], me[1], se[0], se[1])
except:
print >> dest, "\t Failed printing the reprojection error."
print >> dest

#print baselines
for bidx, baseline in enumerate(cself.baselines):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
import itertools
import sys
import pylab as pl
import Image
try:
from PIL import Image # Modern
except ImportError:
import Image # Old import (backward compatibility)
import time

# make numpy print prettier
Expand Down

0 comments on commit cb6fb66

Please sign in to comment.