diff --git a/Article/Expe_auto/buroDetail.png b/Article/Expe_auto/buroDetail.png new file mode 100755 index 0000000000000000000000000000000000000000..a73b1a1656de95efb0a570af8c14c7676d50169a Binary files /dev/null and b/Article/Expe_auto/buroDetail.png differ diff --git a/Article/Expe_auto/perfTable.tex b/Article/Expe_auto/perfTable.tex index e6e0d87782760b42408987d55246946ebd385130..09fcec2bc8dac5952ffdea21909998dfff6fc786 100644 --- a/Article/Expe_auto/perfTable.tex +++ b/Article/Expe_auto/perfTable.tex @@ -1,16 +1,19 @@ \begin{tabular}{|l||r|r|r|r|} \hline -Measure $M$ & \multicolumn{1}{c|}{$T$ (ms)} & \multicolumn{1}{c|}{$N$} -& \multicolumn{1}{c|}{$L$ (pixels)} & \multicolumn{1}{c|}{$W$ (pixels)} \\ +Measure $M$ & \multicolumn{1}{c|}{$T$} & \multicolumn{1}{c|}{$N$} +& \multicolumn{1}{c|}{$L$} & \multicolumn{1}{c|}{$W$} \\ \hline -$M_{old}$ on image of \RefFig{fig:auto} & 29.51 & 306 & 38.58 & 2.47 \\ -$M_{new}$ on image of \RefFig{fig:auto} & 25.85 & 352 & 33.25 & 2.17 \\ -$M_{new}/M_{old}$ (\%) +$M_{old}$ on image of \RefFig{fig:auto} +& 29.51 ms & 306 segments & 38.58 pixels & 2.47 pixels \\ +$M_{new}$ on image of \RefFig{fig:auto} +& 25.85 ms & 352 segments & 33.25 pixels & 2.17 pixels \\ +\hline \hline +$M_{new}/M_{old}$ (\%) & & & & \\ +\hspace{0.4cm} on image of \RefFig{fig:auto} & \multicolumn{1}{l|}{87.60} & \multicolumn{1}{l|}{115.03} & \multicolumn{1}{l|}{86.18} & \multicolumn{1}{l|}{87.85} \\ -\hline -$M_{new}/M_{old}$ (\%) & & & & \\ -on CannyLines images +\hspace{0.4cm} on the set of test images & & & & \\ +\hspace{0.4cm} on CannyLines images & 86.02 $\pm$ 2.44 & 110.15 $\pm$ 6.51 & 89.23 $\pm$ 5.11 & 84.70 $\pm$ 2.98 \\ \hline \end{tabular} diff --git a/Article/Expe_hard/hardDetailNew.png b/Article/Expe_hard/hardDetailNew.png new file mode 100644 index 0000000000000000000000000000000000000000..4ee88ca837b9a94a69421daca4fb654b9cdcbcd9 Binary files /dev/null and b/Article/Expe_hard/hardDetailNew.png differ diff --git a/Article/Expe_hard/hardDetailOld.png b/Article/Expe_hard/hardDetailOld.png new file mode 100644 index 0000000000000000000000000000000000000000..2cb5c40a315583485993761372f7c536a02eb605 Binary files /dev/null and b/Article/Expe_hard/hardDetailOld.png differ diff --git a/Article/Expe_hard/readme.txt b/Article/Expe_hard/readme.txt index 179ebeb67f9f041130d43b0013cac320db7a2dbc..3ac1d6b5e8281ba85229bbf0930a4722060cda9c 100644 --- a/Article/Expe_hard/readme.txt +++ b/Article/Expe_hard/readme.txt @@ -7,3 +7,7 @@ m : detection auto avec le nouveau detecteur p : sauve l'image capture.png -> ismm/Expe_hard/hardNew.png 6 : detection auto avec l'ancien detecteur p : sauve l'image capture.png -> ismm/Expe_hard/hardOld.png + +Pour les images hardDetailNew.png et hardDetailOld.png, +selectionner le coin haut gauche de l'image depuis le +point (346, 140). diff --git a/Article/Fig_notions/bswidth.tex b/Article/Fig_notions/bswidth.tex index 5393c1f2048b772da850c4bbe1b7fd423eed4007..3211f8ccbae185133f038c2f3e4a7cbaee272d5f 100644 --- a/Article/Fig_notions/bswidth.tex +++ b/Article/Fig_notions/bswidth.tex @@ -1,7 +1,7 @@ \begin{picture}(220,60) \multiput(0,6)(2,-6){2}{\line(3,1){150}} - \multiput(0,8)(30,6){8}{\color{red}{\line(5,1){10}}} - \multiput(0,18)(30,6){8}{\color{red}{\line(5,1){10}}} + \multiput(0,8)(30,6){8}{\color{blue}{\line(5,1){10}}} + \multiput(0,18)(30,6){8}{\color{blue}{\line(5,1){10}}} \put(45,21){\circle*{3}} \put(55,21){\circle*{3}} \put(65,21){\circle*{3}} @@ -15,8 +15,8 @@ \put(140,36){\vector(0,1){10}} \put(140,62.66){\vector(0,-1){10}} \put(120,58){$\mu_{i-1}$} - \put(160,30){\color{red}{\vector(0,1){10}}} - \put(160,60){\color{red}{\vector(0,-1){10}}} - \put(164,36){\color{red}{$\mu_i$}} - \put(180,60){\color{red}{$\mathcal{B}_{i}$}} + \put(160,30){\color{blue}{\vector(0,1){10}}} + \put(160,60){\color{blue}{\vector(0,-1){10}}} + \put(164,36){\color{blue}{$\mu_i$}} + \put(180,60){\color{blue}{$\mathcal{B}_{i}$}} \end{picture} diff --git a/Article/Fig_notions/escapeLightFirst_full.png b/Article/Fig_notions/escapeLightFirst_full.png new file mode 100644 index 0000000000000000000000000000000000000000..ba6cd0d5744e93af7981d9105b34fc86c881183f Binary files /dev/null and b/Article/Fig_notions/escapeLightFirst_full.png differ diff --git a/Article/Fig_notions/escapeLightFirst_zoom.png b/Article/Fig_notions/escapeLightFirst_zoom.png new file mode 100644 index 0000000000000000000000000000000000000000..f57f8f99c3f4833a06bdf7de393282fee5f2346a Binary files /dev/null and b/Article/Fig_notions/escapeLightFirst_zoom.png differ diff --git a/Article/Fig_notions/escapeLightSecond_full.png b/Article/Fig_notions/escapeLightSecond_full.png new file mode 100644 index 0000000000000000000000000000000000000000..a20be8592d9e4124a1f35598cb955cddeea4df25 Binary files /dev/null and b/Article/Fig_notions/escapeLightSecond_full.png differ diff --git a/Article/Fig_notions/escapeLightSecond_zoom.png b/Article/Fig_notions/escapeLightSecond_zoom.png new file mode 100644 index 0000000000000000000000000000000000000000..12f1ad7475dd8c3bd49d1e8bbe94d70f9bfc790d Binary files /dev/null and b/Article/Fig_notions/escapeLightSecond_zoom.png differ diff --git a/Article/Fig_notions/escapeLightThird_full.png b/Article/Fig_notions/escapeLightThird_full.png new file mode 100644 index 0000000000000000000000000000000000000000..bd1d7764bedc02c20c385e6b90e687d9b3dd7909 Binary files /dev/null and b/Article/Fig_notions/escapeLightThird_full.png differ diff --git a/Article/Fig_notions/escapeLightThird_zoom.png b/Article/Fig_notions/escapeLightThird_zoom.png new file mode 100644 index 0000000000000000000000000000000000000000..94ac117da0b9730afed01816d0aeae5daa5ae1e2 Binary files /dev/null and b/Article/Fig_notions/escapeLightThird_zoom.png differ diff --git a/Article/Fig_notions/readme.txt b/Article/Fig_notions/readme.txt new file mode 100644 index 0000000000000000000000000000000000000000..50f0d123859d440867633a7dfff0e51ceb9cf921 --- /dev/null +++ b/Article/Fig_notions/readme.txt @@ -0,0 +1,34 @@ +Seg_adaption est le code qui a fourni adaption*_*.png +a partir de test_adapt.txt +0 pour lancer le test +1 pour ouvrir la vue de structure ++ pour zoomer une fois +se caler en bas a droite avec les fleches +i - i pour voir les scans bounds +p pour le screenshot -> structure.png +I pour voir les scans +p pour le screenshot -> structure.png +Avec gimp, selection de la zone (516,70) (174,250) + + + +Le meme exemple a servi a produire une premiere figure escape +sur le segment P1 (181, 226), P2 (178, 205) +Avec gimp, selection de la zone (159,115) (355,203) + + + +Seg_escape est le code qui a fourni escape*_*.png +a partir de test_escape.txt +En vue principale : +Ctrl-q pour basculer entre scan statique ou adaptatif +En vue d'analyse (touche 1) : +i pour selectionner les vues de scan +Ctrl-j pour visualiser la selection utilisateur +Avec gimp, selection de la zone (333,227)(344,208) + + +Production des images plus claires : +6 y pour avoir un niveau de sombreur a 30 +Avec gimp, selection de la zone (58,127)(520,275) +pour avoir des images 454x148 a l'arrivee. diff --git a/Article/Fig_synth/res.txt b/Article/Fig_synth/res.txt index ff45cfc0fbab9e67b780ae609686f73cf4aec16b..d6862a96d7592c2c30c9a309a980ebdb53452f62 100644 --- a/Article/Fig_synth/res.txt +++ b/Article/Fig_synth/res.txt @@ -1,36 +1,38 @@ -1000 cartes avec 1000 segments noirs sur fond blanc -re-estimation de la largeur en retirant un biais de 1.4 - RESULTS FOR THE OLD DETECTOR -69.719 (pm 20.3805) segments searches (local min) / image -25.23 (pm 6.65638) provided segments / image -10.766 (pm 1.96395) provided long segments / image -2.298 (pm 2.82935) undetected segments per image -88.3997 (pm 4.31352) % of points found -2.27666 (pm 1.50916) % of points found more than once (redetections) -32.2193 (pm 13.8132) % false points produced -Precision : 0.732884 (pm 0.0844506) -Biased width : 4.57922 (0.38789) per matched segment -Width : 3.37696 (0.350989) per matched segment -Width difference : 0.64275 (0.319964) per matched segment -Absolute width difference : 0.874094 (0.288227) per matched segment -Angle difference : 0.0497484 (0.756378) degrees per matched segment -Absolute angle difference : 1.2933 (0.92141) per matched segment -Absolute long edge angle difference : 0.44657 (0.55775) per matched segment +66.841 (pm 23.0353) segments searches (local min) / image +25.351 (pm 7.16695) provided segments / image +10.41 (pm 1.84318) provided long segments / image +2.527 (pm 2.54081) undetected segments per image +Recall : 89.0911 (pm 3.94178) % of points found +2.40181 (pm 1.52098) % of points found more than once (redetections) +34.8326 (pm 16.4621) % false points produced +Precision : 0.718919 (pm 0.0973014) +Statistical precision : 0.727566 (pm 0.0969161) +Statistical recall : 0.891995 (pm 0.0394028) +Statistical F-measure : 0.798543 (pm 0.0677593) +Biased width : 4.64042 (0.340364) per matched segment +Width : 3.42451 (0.334641) per matched segment +Width difference : 0.717033 (0.34932) per matched segment +Absolute width difference : 0.920479 (0.309156) per matched segment +Angle difference : -0.246099 (1.33358) degrees per matched segment +Absolute angle difference : 1.48162 (1.41907) per matched segment +Absolute long edge angle difference : 0.542687 (1.08617) per matched segment RESULTS FOR THE NEW DETECTOR -63.6 (pm 17.4179) segments searches (local min) / image -23.722 (pm 4.90028) provided segments / image -11.619 (pm 2.08619) provided long segments / image -0.475 (pm 0.756272) undetected segments per image -89.813 (pm 3.17276) % of points found -1.83739 (pm 1.3875) % of points found more than once (redetections) -22.5376 (pm 10.2339) % false points produced -Precision : 0.799399 (pm 0.0701648) -Biased width : 4.49693 (0.320961) per matched segment -Width : 3.26288 (0.297711) per matched segment -Width difference : 0.408348 (0.27149) per matched segment -Absolute width difference : 0.741648 (0.24851) per matched segment -Angle difference : 0.0354951 (0.641921) degrees per matched segment -Absolute angle difference : 0.982936 (0.696344) per matched segment -Long edge absolute angle difference : 0.480284 (0.568648) per matched segment - +62.393 (pm 17.1718) segments searches (local min) / image +24.351 (pm 5.02624) provided segments / image +11.145 (pm 1.91824) provided long segments / image +0.637 (pm 0.909978) undetected segments per image +Recall : 90.0194 (pm 2.77084) % of points found +1.78012 (pm 1.21784) % of points found more than once (redetections) +23.7471 (pm 8.87023) % false points produced +Precision : 0.791264 (pm 0.0630463) +Statistical precision : 0.791896 (pm 0.0630431) +Statistical recall : 0.900763 (pm 0.0277026) +Statistical F-measure : 0.84169 (pm 0.0416617) +Biased width : 4.5098 (0.252717) per matched segment +Width : 3.28158 (0.239712) per matched segment +Width difference : 0.462984 (0.255638) per matched segment +Absolute width difference : 0.764102 (0.231734) per matched segment +Angle difference : -0.141146 (0.721153) degrees per matched segment +Absolute angle difference : 1.05426 (0.801184) per matched segment +Long edge absolute angle difference : 0.529121 (0.684013) per matched segment diff --git a/Article/Fig_synth/statsTable.tex b/Article/Fig_synth/statsTable.tex index b4da315662307aa3f829bb677f8ce907abed6dbf..33c04ff99e32aa8c793db115502d02eed990a2bf 100644 --- a/Article/Fig_synth/statsTable.tex +++ b/Article/Fig_synth/statsTable.tex @@ -3,18 +3,20 @@ Detector : & \multicolumn{3}{c|}{old} & \multicolumn{3}{c|}{new} \\ \hline Detected blurred segments per image -& 25.23 & $\pm$ & 6.66 & 23.72 & $\pm$ & 4.90 \\ +& 25.35 & $\pm$ & 7.17 & 24.35 & $\pm$ & 5.03 \\ Detected long (> 40 pixels) blurred segments per image -& 10.77 & $\pm$ & 1.96 & 11.62 & $\pm$ & 2.09 \\ +& 10.41 & $\pm$ & 1.84 & 11.14 & $\pm$ & 1.92 \\ Undetected input segments per image -& 2.30 & $\pm$ & 2.83 & 0.47 & $\pm$ & 0.76 \\ -Ratio of true detection (\%) : $\#(D\cap S)/\#S$ -& 88.40 & $\pm$ & 4.31 & 89.81 & $\pm$ & 3.17 \\ -Precision (\%) : $\#(D\cap S)/\#D$ -& 73.29 & $\pm$ & 8.45 & 79.94 & $\pm$ & 7.02 \\ +& 2.53 & $\pm$ & 2.54 & 0.64 & $\pm$ & 0.91 \\ +Precision (\%) : $P = \#(D\cap S)/\#D$ +& 72.76 & $\pm$ & 9.69 & 79.19 & $\pm$ & 6.30 \\ +Recall (ratio of true detection) (\%) : $R = \#(D\cap S)/\#S$ +& 89.20 & $\pm$ & 3.94 & 90.08 & $\pm$ & 2.77 \\ +F-measure (harmonic mean) (\%) : $F = 2\times P\times R/(P+R)$ +& 79.85 & $\pm$ & 6.78 & 84.17 & $\pm$ & 4.17 \\ Width difference (in pixels) to matched input segment -& 0.87 & $\pm$ & 0.29 & 0.74 & $\pm$ & 0.24 \\ +& 0.92 & $\pm$ & 0.31 & 0.76 & $\pm$ & 0.23 \\ Angle difference (in degrees) to matched input segment -& 1.29 & $\pm$ & 0.92 & 0.98 & $\pm$ & 0.70 \\ +& 1.48 & $\pm$ & 1.42 & 1.05 & $\pm$ & 0.80 \\ \hline \end{tabular} diff --git a/Article/biblio.bib b/Article/biblio.bib index 5df469aa1210f967deb6cc8e49bfba81cc421324..90f6b92d3573c31b50d6c9f490b6549cf24c658d 100755 --- a/Article/biblio.bib +++ b/Article/biblio.bib @@ -32,7 +32,7 @@ @inproceedings{DebledAl05, - title = {Blurred Segments Decomposition in Linear Time}, + title = {Blurred segments decomposition in linear time}, author = {Debled-Rennesson, Isabelle and Feschet, Fabien and Rouyer-Degli, Jocelyne}, booktitle = {Proc. of Int. Conf. on DGCI}, @@ -43,7 +43,7 @@ pages = {371-382}, optaddress = {Poitiers, France}, optmonth = {April}, - publisher = {Springer} + optpublisher = {Springer} } diff --git a/Article/conclusion.tex b/Article/conclusion.tex index 240817f6d75b51c3c15a2c0a4fa0436aad3dbc13..3347917291076da1fa438d2dda316c158fcd80a4 100755 --- a/Article/conclusion.tex +++ b/Article/conclusion.tex @@ -3,36 +3,39 @@ \label{sec:conclusion} This paper introduced a new straight edge detector based on a local analysis of -the image gradient and on the use of blurred segments to vehiculate an +the image gradient and on the use of blurred segments to embed an estimation of the edge thickness. It relies on directional scans of the image around maximal values of the gradient magnitude, that have previously been presented in \cite{KerautretEven09}. -Despite of good performances achieved, the former approach suffers of two -major drawbacks: the inaccurate estimation of the blurred segment width -and orientation, and the lack of guarantee that it is completely detected. -These limitations were solved through the integration of two new concepts: +%Despite of good performances achieved, the former approach suffers of two +%major drawbacks: the inaccurate estimation of the blurred segment width +%and orientation, and the lack of guarantee that it is completely detected. +%These limitations were solved through the integration of two new concepts: +%adaptive directional scans that continuously adjust the scan strip +%to the detected blurred segment direction; +The main limitations of the former approach were solved through the integration +of two new concepts: adaptive directional scans that continuously adjust the scan strip -to the detected blurred segment direction; +to the detected edge direction; the control of the assigned width based on the observation of the -blurred segment thickenning in the early stage of its expansion. +blurred segment growth. +Expected gains in accuracy and execution time were confirmed by the +held experiments. -Expected gains in execution time linked to the suppression of a useless -repetition of the fine tracking stage were confirmed by the experiments -both in supervised and unsupervised contexts. -The residual weakness is the high sensitivity to the initial conditions -despite of the valuable enhancement brought by the duplication of the -initial detection. -Disturbing gradient perturbations in the early stage of the edge expansion, -possibly due to the presence of close edges, can deeply affect the output -blurred segment. -In supervised context, the user can easily select a favourable area where +A residual weakness of the approach is the sensitivity to the initial +conditions. +In supervised context, the user can select a favourable area where the awaited edge is dominant. -But this default remains quite sensible in unsupervised context. - -In future works, we intend to provide some solutions for this drawback -by scoring the detection result on the base of a characterization of the -initial context. +This task is made quite easier, thanks to the stabilization produced by +the duplication of the initial detection. +But in unsupervised context, gradient perturbations in the early stage of +the edge expansion, msotly due to the presence of close edges, can deeply +affect the result. +In future works, we intend to provide solutions to this drawback +by scoring the detection result on the basis of a characterization of the +local context. +% Then experimental validation of the consistency of the estimated width and orientation values on real situations are planned in different application fields. diff --git a/Article/expe.tex b/Article/expe.tex index 25b1d56ef3b320e18e89fdcee02aff7e3c1572f6..9454e82b5a7a2ffa3662af07dcabae0719f6d18f 100755 --- a/Article/expe.tex +++ b/Article/expe.tex @@ -11,6 +11,12 @@ For a fair comparison, the process flow of the former method (the initial detection followed by two refinement steps) is integrated as an option into the code of the new detector, so that both methods rely on the same optimized basic routines. +During all these experiments, only the blurred segment size and its +orientation compared to the initial stroke were tested at the end of +the initial detection, and only the segment size was tested at the end +of the fine tracking stage. +All the other tests, sparsity or fragmentation, were disabled. +The segment minimal size was set to 5 pixels, except where precised. The first test (\RefFig{fig:synth}) compares the performance of both detectors on a set of 1000 synthesized images containing 10 randomly @@ -18,20 +24,14 @@ 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 such perfect image, the numerical error on the gradient extraction -biases the line width measures. This bias was estimated in quasi ideal -context (only one input segment, thus no risk of perturbation) +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. -Although the effect of the old detector weaknesses should be reduced in -this low gradient noise context, the results of \RefTab{tab:synth} show +The results of \RefTab{tab:synth} show slightly better width and angle measurements for the new detector. The new detector shows more precise, with a smaller amount of false detections and succeeds in finding most of the input segments. -The second test (\RefFig{fig:hard}) visually compares the results of both -detectors on quite noisy images, also difficult to process for other -detectors from the literature. -The new detector provides less outliers and misaligned segments, and -globally more relevant informations to infere the structure of the brick wall. \begin{figure}[h] %\center \begin{tabular}{ @@ -65,29 +65,7 @@ $S$ is the set of all the input segments, $D$ the set of all the detected blurred segments.} \label{tab:synth} \end{table} -\begin{figure} -%\center - \begin{tabular}{ - c@{\hspace{0.1cm}}c@{\hspace{0.1cm}}c@{\hspace{0.1cm}}} - \includegraphics[width=0.32\textwidth]{Fig_method/parpaings.png} & - \includegraphics[width=0.32\textwidth]{Expe_hard/hardOld.png} & - \includegraphics[width=0.32\textwidth]{Expe_hard/hardNew.png} - \begin{picture}(1,1) - {\color{dwhite}{ - \put(-286,4.5){\circle*{8}} - \put(-171,4.5){\circle*{8}} - \put(-58,4.5){\circle*{8}} - }} - \put(-288.5,2){a} - \put(-173.5,2){b} - \put(-60.5,2){c} - \end{picture} - \end{tabular} - \caption{Detection results on quite textured images: - one of the tested images (a), - the segments found by the old detector (b) - and those found by the new detector (c).} - \label{fig:hard} -\end{figure} \input{expeAuto} + +\input{expeHard} diff --git a/Article/expeAuto.tex b/Article/expeAuto.tex index c46db99356cd1976b2e4ef0b24b5d24486cf51c6..8538b88063b920f9bee9603476aa8690b4c4b490 100755 --- a/Article/expeAuto.tex +++ b/Article/expeAuto.tex @@ -1,16 +1,13 @@ - -The third campaign of tests aims at evaluating the performance of the new -detector with respect to the previous one on a selection of more standard -images. +The next experiments aim at evaluating the performance of the new +detector with respect to the previous one on a test set composed of a +selection of 20 real images. +One of them is displayed on \RefFig{fig:auto}. Compared measures $M$ are the execution time $T$, the amount $N$ of detected -blurred segments, the mean length $L$ and the mean width $W$ of the detected -segments. +blurred segments, their mean length $L$ and their mean width $W$. For the sake of objectivity, these results are also compared to the same measurements made on the 20 images data base used for the CannyLine line segment detector \cite{LuAl15}. -\RefTab{tab:auto} gives the measures obtained on one of the selected images -(\RefFig{fig:auto}) and the result of a systematic test on the CannyLine -data base. +\RefTab{tab:auto} gives the achieved results. \begin{figure}[h] %\center \begin{tabular}{ @@ -20,7 +17,8 @@ data base. % \includegraphics[width=0.32\textwidth]{Expe_auto/coloredNew.png} \\ \includegraphics[width=0.32\textwidth]{Expe_auto/bsOld.png} & \includegraphics[width=0.32\textwidth]{Expe_auto/bsNew.png} \\ - & \includegraphics[width=0.22\textwidth]{Expe_auto/dssDetailOld.png} & + \includegraphics[width=0.22\textwidth]{Expe_auto/buroDetail.png} & + \includegraphics[width=0.22\textwidth]{Expe_auto/dssDetailOld.png} & \includegraphics[width=0.22\textwidth]{Expe_auto/dssDetailNew.png} \begin{picture}(1,1) {\color{red}{ @@ -28,25 +26,30 @@ data base. \put(-5.5,31){\vector(-2,-1){20}} \put(-133.5,31){\framebox(28,9)} \put(-117.5,31){\vector(-2,-1){20}} + \put(-247.5,31){\framebox(28,9)} + \put(-231.5,31){\vector(-2,-1){20}} }} {\color{dwhite}{ \put(-291,32.5){\circle*{8}} \put(-177,32.5){\circle*{8}} \put(-63,32.5){\circle*{8}} + \put(-302,4.5){\circle*{8}} \put(-188,4.5){\circle*{8}} \put(-75,4.5){\circle*{8}} }} \put(-293.5,30){a} \put(-179.5,30){b} \put(-65.5,30){c} - \put(-191,2){d} - \put(-77.5,2){e} + \put(-305,2){d} + \put(-191,2){e} + \put(-77.5,2){f} \end{picture} \end{tabular} - \caption{Automatic detection on standard images: + \caption{Automatic detection on real images: an input image (a), the segments found by the old detector (b) and those found by the new detector (c), and a detail of the - enclosing digital segments for both old (d) and new (e) detectors.} + image (d) and the enclosing digital segments for both old (e) + and new (f) detectors.} \label{fig:auto} \end{figure} \begin{table} @@ -69,7 +72,7 @@ Found edges are thus more fragmented. The relevance of this behavior depends strongly on application requirements. Therefore the control of the assigned width is left as an option, the user can let or cancel it. -In both case, it could be interesting to combine the detector with a tool +In both case, it could be useful to combine the detector with a tool to merge aligned segments. %Although these observations in unsupervised context should be reproduced diff --git a/Article/expeHard.tex b/Article/expeHard.tex index 087e0dfc0552aba5a9b6b79abe40b5df768d6374..be775d9976e3dcb18c214fe410b70253aee1d081 100755 --- a/Article/expeHard.tex +++ b/Article/expeHard.tex @@ -1,29 +1,33 @@ - -The second test (\RefFig{fig:hard}) visually compares the results of -both detectors on quite difficult images with a lot of gradient noise. -The new detector provides less outliers and misaligned segments, and -globally more relevant informations to infere the structure of the brick wall. -\begin{figure}[h] -%\center +The last test visually compares the results of both detectors on quite textured +images, also difficult to process for other detectors from the literature. +The minimal size parameter was raised to 12 pixels to reject small segments +considered as outliers. +On the example of \RefFig{fig:hard}, the new detector provides less residual +outliers and misaligned segments, and globally more relevant informations +to infere the structure of the brick wall. +\begin{figure} + \center \begin{tabular}{ c@{\hspace{0.1cm}}c@{\hspace{0.1cm}}c@{\hspace{0.1cm}}} - \includegraphics[width=0.32\textwidth]{Fig_method/parpaings.png} & - \includegraphics[width=0.32\textwidth]{Fig_hard/hardOld.png} & - \includegraphics[width=0.32\textwidth]{Fig_hard/hardNew.png} + \includegraphics[width=0.205\textwidth]{Fig_method/parpaings.png} & + \includegraphics[width=0.32\textwidth]{Expe_hard/hardDetailOld.png} & + \includegraphics[width=0.32\textwidth]{Expe_hard/hardDetailNew.png} \begin{picture}(1,1) + {\color{red}{ + \put(-302,34){\framebox(29,11.5)} + }} {\color{dwhite}{ - \put(-286,4.5){\circle*{8}} + \put(-266,4.5){\circle*{8}} \put(-171,4.5){\circle*{8}} \put(-58,4.5){\circle*{8}} }} - \put(-288.5,2){a} + \put(-268.5,2){a} \put(-173.5,2){b} \put(-60.5,2){c} \end{picture} \end{tabular} - \caption{Detection results on quite textured images: - one of the tested images (a), - the segments found by the old detector (b) - and those found by the new detector (c).} + \caption{Results on quite textured images: test image (a), + detail (top left corner) on the segments found by the old + detector (b) and on those found by the new detector (c).} \label{fig:hard} \end{figure} diff --git a/Article/method.tex b/Article/method.tex index e9e5f8f3313422492bfdd600a2059e25befcb6eb..d4640a588ff9e81c8c5bd43c03b663616646403c 100755 --- a/Article/method.tex +++ b/Article/method.tex @@ -37,8 +37,8 @@ The output segment $\mathcal{B}'$ is finally tested according to the application needs. Too short, too sparse or too fragmented segments can be rejected. Length, sparsity or fragmentation thresholds are intuitive parameters left at the end user disposal. -None of these tests are activated for the experimental stage in order -to put forward achievable performance. +%None of these tests are activated for the experimental stage in order +%to put forward achievable performance. \subsection{Adaptive directional scan} @@ -51,36 +51,36 @@ A second search is then run using another directional scan aligned on the detected segment (\RefFig{fig:escape} b). In the given example, an outlier added to the initial segment leads to a wrong orientation value. -But even in case of a correct detection, this estimated orientation -is subject to the numerization rounding, and the longer the real segment -to detect, the higher the probability to fail again on a blurred segment -escape from the directional scan. +But even in case of a correct detection, this estimated orientation is +subject to the numerization rounding, and the longer the real segment is, +the higher the probability gets to fail again on an escape from the scan strip. \begin{figure}[h] \center \begin{tabular}{c@{\hspace{0.2cm}}c} - \includegraphics[width=0.48\textwidth]{Fig_notions/escapeFirst_zoom.png} & - \includegraphics[width=0.48\textwidth]{Fig_notions/escapeSecond_zoom.png} \\ + \includegraphics[width=0.48\textwidth]{Fig_notions/escapeLightFirst_zoom.png} & + \includegraphics[width=0.48\textwidth]{Fig_notions/escapeLightSecond_zoom.png} \\ \multicolumn{2}{c}{ - \includegraphics[width=0.62\textwidth]{Fig_notions/escapeThird_zoom.png}} + \includegraphics[width=0.62\textwidth]{Fig_notions/escapeLightThird_zoom.png}} \begin{picture}(1,1)(0,0) {\color{dwhite}{ - \put(-260,87.5){\circle*{8}} - \put(-86,87.5){\circle*{8}} - \put(-172,7.5){\circle*{8}} + \put(-260,78.5){\circle*{8}} + \put(-86,78.5){\circle*{8}} + \put(-172,4.5){\circle*{8}} }} - \put(-263,85){a} - \put(-89,85){b} - \put(-175,5){c} + \put(-262.5,76){a} + \put(-89,75.5){b} + \put(-174.5,2){c} \end{picture} \end{tabular} \caption{Aborted detections on side escapes of static directional scans and successful detection using an adaptive directional scan. The last points added to the left of the blurred segment during initial detection (a) lead to a bad estimation of its - orientation, and thus to an incomplete fine detection with a - classical directional scan (b). An adaptive directional scan - can continue the segment expansion as far as necessary (c). + orientation, and thus to an incomplete fine tracking with a + classical directional scan (b). An adaptive directional scan at + the place of the static one allows to continue the segment + expansion as far as necessary (c). On the pictures, the input selection is drawn in red color, the scan strip bounds in blue and the detected blurred segment in green.} @@ -108,22 +108,26 @@ ADS = \left\{ S_i = \mathcal{D}_i \cap \mathcal{N}_i \cap \mathcal{I} \left| \begin{array}{l} \delta(\mathcal{N}_i) = - \delta^{-1}(\mathcal{D}_0) \\ -\wedge~ h(\mathcal{N}_i) = h(\mathcal{N}_{i-1}) + p(\mathcal{D}) \\ -\wedge~ \mathcal{D}_{i} = \mathcal{D} (C_{i-1}, \vec{D}_{i-1}, w_{i-1}), i > 1 +\wedge~ h(\mathcal{N}_i) = h(\mathcal{N}_{i-1}) + p(\mathcal{D}_0) \\ +\wedge~ \mathcal{D}_{i} = \mathcal{D} (C_{i-1}, \vec{D}_{i-1}, w_{i-1}), +i > \lambda \end{array} \right. \right\} \end{equation} -where $C_{i-1}$, $\vec{D}_{i-1}$ and $w_{i-1}$ are a position, a director -vector and a width observed at iteration $i-1$. +where $C_{i}$, $\vec{D}_{i}$ and $w_{i}$ are respectively a position, +a director vector and a width observed at iteration $i$. In the scope of the present detector, $C_{i-1}$ is the intersection of the input selection and the medial axis of $\mathcal{B}_{i-1}$, $\vec{D}_{i-1}$ the support vector of the enclosing digital segment $E(\mathcal{B}_{i-1})$, and $w_{i-1}$ a value slightly greater than the minimal width of $\mathcal{B}_{i-1}$. So the last clause expresses the update of the scan bounds at iteration $i$. -Compared to static directional scans, the scan strip moves while +Compared to static directional scans where the scan strip remains fixed to +the initial line $\mathcal{D}_0$, here the scan strip moves while scan lines remain fixed. -This behavior ensures a complete detection of the blurred segment even -when the orientation is badly estimated (\RefFig{fig:escape} c). +This behavior ensures a complete detection of the blurred segment even when +the orientation of $\mathcal{D}_0$ is badly estimated (\RefFig{fig:escape} c). +In practice, it is started after $\lambda = 20$ iterations when the observed +direction becomes more stable. \subsection{Control of the assigned width} @@ -131,15 +135,15 @@ The assigned width $\varepsilon$ to the blurred segment recognition algorithm is initially set to a large value $\varepsilon_0$ in order to allow the detection of large blurred segments. Then, when no more augmentation of the minimal width is observed after -$\lambda$ iterations ($\mu_{i+\lambda} = \mu_i$), it is set to a much +$\tau$ iterations ($\mu_{i+\tau} = \mu_i$), it is set to a much stricter value able to circumscribe the possible interpretations of the segment, that take into account the digitization margins: \begin{equation} -\varepsilon = \mu_{i+\lambda} + \frac{\textstyle 1}{\textstyle 2} +\varepsilon = \mu_{i+\tau} + \frac{\textstyle 1}{\textstyle 2} \end{equation} This strategy aims at preventing the incorporation of spurious outliers in further parts of the segment. -Setting the observation distance to a constant value $\lambda = 20$ seems +Setting the observation distance to a constant value $\tau = 20$ seems appropriate in most experimented situations. \subsection{Supervised blurred segment detection} @@ -221,7 +225,7 @@ $2~\varepsilon_{ini}$, and $M_j$ is used as start point of the blurred segment; \item the occupancy mask is filled in with the points of the dilated blurred segments $\mathcal{B}_j''$ at the end of each successful detection -(a 21 pixels bowl is used); +(a 21 pixels neighborhood is used); \item points marked as occupied are rejected when selecting candidates for the blurred segment extension in the fine tracking step. \end{enumerate} @@ -240,8 +244,8 @@ the borders. At each position, the multi-detection algorithm is run to collect all the segments found under the stroke. In the present work, the stroke sweeping step $\delta$ is set to 10 pixels. -The automatic detection of blurred segments in a whole image is left -available for testing in an online demonstration at the following address: \\ +The automatic detection of blurred segments in a whole image is left available +for testing from an online demonstration at the following address: \\ \href{http://ipol-geometry.loria.fr/~kerautre/ipol_demo/AdaptDirBS_IPOLDemo}{ \small{\url{ http://ipol-geometry.loria.fr/~kerautre/ipol_demo/AdaptDirBS_IPOLDemo}}}