DemoThreeViewStereoApp Error

24 views
Skip to first unread message

mb

unread,
Jan 11, 2022, 3:24:21 PMJan 11
to BoofCV
Hi, I'm recently trying out your Trinocular Vision implemention using the DemoThreeViewStereoApp available in the demonstration launcher. For all images I tried I get an error message "Number of bands must be the same. 1 vs. 3". I couldn't find this error somewhere in the code to get a hint about what went wrong. Can you maybe help me here?

Thanks in advance! Also many thanks for your great explanation on the topic trinocular stereo vison on Youtube!

Some words about the setup I used to acquire images: three identical monochrome cameras horizontally aligned with a distance of 7 cm. The scene contains a well-textured object at a distance of 1.5 m to the cameras and a office background scene. Apparently enough features could be detected (>1.5k in each) and a sufficient number of features could be matched (600). But then the rectification shows no result. 

Peter A

unread,
Jan 11, 2022, 5:04:54 PMJan 11
to boofcv
Are you sure the images are all saved as grayscale? What that error message is saying is that one image is gray and the other is color. If you don't think that's the case, could you post the images someplace?

--
You received this message because you are subscribed to the Google Groups "BoofCV" group.
To unsubscribe from this group and stop receiving emails from it, send an email to boofcv+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/boofcv/0c415afc-a998-4b9f-b794-93e12d56ac4fn%40googlegroups.com.


--
"Now, now my good man, this is no time for making enemies."    — Voltaire (1694-1778), on his deathbed in response to a priest asking that he renounce Satan.

mb

unread,
Jan 12, 2022, 2:48:55 PMJan 12
to BoofCV
The image dimensions are 2448x2048x1 unit8 and should be grayscale if I'm not mistaken. I also tried it with downsampled images and played around with different settings quite extensively, so far to no avail. I uploaded the files to  https://we.tl/t-e6OyMAlL82, would be great if you would find the time to have a quick look at them. Thank you very much!

Peter A

unread,
Jan 13, 2022, 12:20:46 AMJan 13
to boofcv
It assumed the images had 3 bands. Very simple fix. Latest code in SNAPSHOT branch works and does a decent reconstruction.

mb

unread,
Apr 20, 2022, 1:47:21 AMApr 20
to BoofCV
Thank you, it indeed creates decent reconstructions. I recognized that Boofcv-javafx is not up to date on Maven Central (current version on Maven: 0.31, version on Git: 0.40.1). This causes issues when trying to run some examples using IntelliJ and MavenCentral dependencies. 

To follow up on my question regarding trinocular vision: is it possible to perform calibrated trinocular vision using BoofCV? I.e., calibrate three cameras using BoofCV calibration tools (internal and external calibration), construct the trifocal tensor from the calibration and then reconstruct the scene? 

Peter A

unread,
Apr 22, 2022, 11:33:49 AMApr 22
to boofcv
With the boofcv-javafx issue, is that a transitive dependency or do you explicitly include it? Work was started on that and stopped. Might be removed eventually. There's no need to include it unless you want to help start that project up again.

The code to do a 3-view calibration and reconstruction is certainly there. There isn't a nice tool yet (one is planned) for calibrating an N-camera system with synchronized frames. The semi-manual way to do it would be to use the existing tools to calibrate each camera individually, then use an ECoCheck marker and use that to estimate the extrinsics between the cameras.  For reconstruction from three calibrated views, the easiest way might be to modify the uncalibrated example by removing all the code where it does self calibration. Then feeding in known calibration values you found previously.

FYI there is an active project right now where a batch multi-camera visual SLAM algorithm is being implemented. While overkill, that might make these tasks easier.

- Peter
Reply all
Reply to author
Forward
0 new messages