Requires at least Qt5.5
Compilation by qmake
and make
Execution : FBSD <imageName>
Detects and edits segments in naivelines.txt : FBSD -out <imageName>
Test on synthetized images : FBSD -random
Online demo also available.
First tests compare the performance of the detector with and without adaptive directional scans (ADS) and assigned thickness control (ATC). On the detector without ADS, the fine tracking step must be performed twice to get less risk of growing blurred segment escape from the scan strip.
These tests compare both versions on a set of 1000 synthesized images containing 10 randomly placed input segments with random width between 2 and 5 pixels. The absolute value of the difference of each found segment to its matched input segment is measured. On these groundtruth image, the numerical error on the gradient extraction biases the line width measures. This bias was first estimated using 1000 images containing only one input segment (no possible interaction) and the found value (1.4 pixel) was taken into account in the test. Results are given in the following table. If we call S the count of pixels of all input segments in an image, D the count of pixels of all output blurred segments, and I the count of successfully detected pixels (intersection of D ans S), the given measures are 1) the count of output blurred segments, 2) the count of output long (> 40 pixels) blurred segments, 3) the count of undetected input segments, 4) the precision P = I/D, 5) the recall R = I/S, 6) the F-measure F = 2.P.R / (P+R), 7) the absolute value of the width difference between matched output segments with input segments, and 8) the absolute value of the angle difference between matched output segments with input segments.
Figure 1: Evaluation on synthesized images: two of the randomly generated images(left), bounding lines of output blurred segments without (middle) and with (right) ADS and ATC concepts.
Table 1: Measured performance on both Figure 1 image examples and on a whole 1000 synthesized images set, without and with adaptive directional scans and assigned width control.
Next tests compare both versions on real images: first the set of 102 images of York Urban data base [1] augmented with manually extracted groundtruth lines, then selected images for more detailed visual analysis. Reported measures are execution time T, groundtruth covering ratio C (only for the York Urban data base), number of output line segments N, mean length of output line segments L/N, and mean thickness of output line segments W.
Figure 2: Automatic detection on real images: P1020928 image from York Urban data base [1] (a), the associated groundtruth lines (d), the naive lines found without (b) and with (e) ADS and ATC concepts, the thick lines found without (c) and with (f) ADS and ATC concepts.
Measure | T (ms) | C (%) | N | L/N (pixels) | W (pixels) |
---|---|---|---|---|---|
Without ADS and ATC | 75.19 16.60 | 70.2 10.1 | 421 98 | 46.22 pixels 8.60 | 2.20 0.16 |
With ADS and ATC | 66.62 15.47 | 67.9 9.6 | 478 111 | 41.67 7.53 | 1.89 0.13 |
Table 2: Measure with and without ADS and ATC concepts on the York Urban Database [1].
Figure 3: Automatic detection on real images: 800x533 office image (a), the segments found without (b) and with (c) ADS and ATC concepts, a detail of the image (d,g), the points of detected blurred segments without (e) and with (f) ADS and ATC concepts and the bounding lines of detected blurred segments without (h) and with (i) ADS and ATC concepts.
Measure | T (ms) | N | L/N (pixels) | W (pixels) |
---|---|---|---|---|
Without ADS and ATC | 48.16 | 254 | 53.92 | 1.99 |
With ADS and ATC | 42.17 | 285 | 49.69 | 1.69 |
Table 3: Measure with and without ADS and ATC concepts on office image.
Figure 4: Automatic detection on real images: 768x512 castle image (a), the segments found without (b) and with (c) ADS and ATC concepts, a detail of the image (d,g), the points of detected blurred segments without (e) and with (f) ADS and ATC concepts and the bounding lines of detected blurred segments without (h) and with (i) ADS and ATC concepts.
Measure | T (ms) | N | L/N (pixels) | W (pixels) |
---|---|---|---|---|
Without ADS and ATC | 104.30 | 361 | 36.58 | 2.23 |
With ADS and ATC | 94.21 | 424 | 32.18 | 1.98 |
Table 4: Measure with and without ADS and ATC concepts on castle image.
Shorter execution time is achieved with the new concepts. Detected blurred segments are shorter but thinner. Obviously the constant assigned thickness augments the probability to extend the segments with outlier edge points as can be noticed in the detail of office and castle images. Moreover, brick joints are better detected in castle image.
[1] Denis, P., Elder, J.H. and Estrada, F.J.: Efficient edge-based methods for estimating Manhattan frames in urban imagery. In: European Conference on Computer Vision. Springer LNCS 5303, pp. 197-210 (2008).
Use right mouse button to define an input stroke.
On Mac systems, Cmd keys should be used instead of Ctrl keys.
Key | Description |
---|---|
Ctrl-B | Toggles the window background (in cycle). |
Ctrl-K | Sets fragmentation test on or off (off by default). |
Ctrl-M | Sets the multi-detection on or off (off by default). |
Ctrl-O | Sets the detection measurement display or off (off by default). |
Ctrl-S | Sets final size test on or off (on by default). |
Ctrl-X | Sets ADS and ATC tools (on by default). |
Ctrl-Y | Sets final sparsity test on or off (off by default). |
----- | ------------- |
a | Registers the last blurred segment. |
b/B | Sets image gray level. |
c/C | Toggles blurred segment color set. |
d/D | Toggles blurred segment display style. |
k/K | Tunes the fragments (connected components) minimal size. |
m | Detects all the segments in the image. |
o | Saves detected segment(s) in seg(s).txt |
p | Saves detection window in capture.png |
q | Displays all the registered blurred segments. |
r/R | Tunes the stroke sweeping step of automatic detections. |
s/S | Tunes the minimal size of detected blurred segments. |
u | Runs the last detection again. |
w/W | Tunes the initial assigned width. |
x | Withdraws the registered segments. |
<> | Horizontal shift (on large images, example: general.png). |
^v | Vertical shift (on large images, example: general.png). |
+- | Zoom (on large images, example: general.png). |
Command : FBSD Images/couloir.gif
Right mouse click and drag :
Keys "Ctrl-m" and "u" :
Key "m" :