Graph Cut and its application in computer Vision

Source: Internet
Author: User

Graph Cut and its application in computer Vision

Original source:

Http://lincccc.blogspot.tw/2011/04/graph-cut-and-its-application-in.html

The network flow algorithm was originally used to solve the optimization problems of flow network, such as water pipe network, communication transmission and city traffic. Graph Cut is one of the most common algorithms used to solve the minimum cut of a flow network, which is to find a set of edges with the smallest total capacity, and removing all the edges in the set will block the network. Images and videos can also be viewed as networks (or MRF), with pixels as nodes, which define the energy value (capacity) of the edges between neighboring pixels. Since the late 90, Graph cut has been introduced into computer vision, image processing, and machine learning to optimize classification, segmentation, and synthesis.

the Max-flow and min-cost problem:
defines the graph (or stream network) G = (V, E) , which can be either a direction graph or a non-direction graph. All edges in the figure E (U, v) ∈e are accompanied by a non-negative capacity of C (U, v) ≥0 , which is the maximum amount of traffic that the edge can withstand. The figure usually defines two special nodes, the source point s and the end point t ; there are graphs with multiple endpoints, and the Max-flow solution to the NP problem, which needs to be converted to the double endpoint problem to solve the suboptimal solution. Defines a stream on figure G for F:vxv→r that meets the following criteria:
     Capacity constrain, for all u, v∈v , F (U, v) ≤c (U, v)
     Skew symmetry, for all u, v∈v , F (U, v) =﹣f (U, v)
      Flow Conservation, for all u∈v﹣{s, T} and v∈v , ∑f (u, V) = 0
all from s The sum of the traffic is the total flow of the entire graph. As shown, the current total flow of the graph is 19, and the maximum value is not reached.

Cut divides all nodes of the entire graph into two disjoint sets S and T , such as s∈s , t∈t . The cut capacity is defined as:
C (S, T) =∑x∈s∑y∈t C (x, y) . The
Min-cut (minimum cut) is the smallest of all cuts in the graph. It is very difficult to find min-cut directly on the algorithm, according to the maximum flow minimum cut theorem, that is, the maximum flow of the graph is equal to the minimum cutting capacity of the graph, and the problem is usually converted to the equivalent Max-flow problem (theoretical deduction point I).

Max-flow and Min-cost algorithms:
The solution of the Max-flow problem has two classical algorithms, the augmented path [1] and the Push-relabel [2]. The Augmented path class algorithm follows the principle of gradual progression, constantly looking for available paths from s to T on the graph, and slowly lifting the total flow of the graph to the maximum starting from 0, while the Push-relabel class algorithm starts from the local, always as far as possible to convey more traffic to the graph, To achieve the balance between nodes in the repeated push and relabel operations is a kind of mimicry of water flow. The Push-relabel class algorithm has a high degree of parallelism, which is suitable for GPU acceleration, and the general process points me. There are many variants of the
Augmented path class algorithm, but most have the following characteristics: 1) maintain the residual capacity network, 2) approximate maximum flow by looking for augmenting path. Augmenting path has the form: S, E1, V1, E2, v2, ..., EK, T , where there are no duplicate nodes, no saturated forward edges, and a back edge of the empty traffic. There are many forms of definition of the residual network, where we define the residual capacity of the edge (Redsidual CAPACITY,RC) when it is a forward edge equal to C (i, J) –f (i, J) , when it is a back edge equal to F (i, J) , as shown in. The residual capacity of the

augmenting path is the minimum of its residual capacity for each edge, such as a path with a residual capacity of 1. The Ford-fulkerson algorithm continuously queries the residual network for augmenting path, such as using breadth or depth-first search, until no path can be found. Example dot me. BOYKOV[3] proposed a two-way search and reuse of the search tree augmented path algorithm, although the theoretical complexity is high, but in practical applications, but the efficiency is high, so many applications that need graph cut use the source code provided by Boykov.

applications in computer vision:
Many problems in computer vision can be attributed to the optimization of the quantization equation. The problem of segmentation, which defines the probability that each pixel belongs to the foreground or the background, becomes the problem of how to make the whole probability quantization equation the biggest one. Sometimes, of course, we also need to define smoothing items that constrain the property changes of neighboring pixels. This creates a class of energy optimization equations that are most common in vision:
      E (f) = Esmooth (f) + Edata (f )
1-dimensional graphs can also be solved using dynamic programming methods, But more than 2-D is mostly using graph cut because of its geometric complexity. Typical applications are segmentation, Stereo matching, Image restoration, Motion estimation, and so on. There are different graphs, adjacent constraints and energy functions depending on the application. Kolmogorov[4] studied what kind of energy equation can be optimized with graph cut, and proposed the method of automatic conversion of ternary and following energy functions into graphs.

multi-label graph Cut:
Sometimes, depending on the needs of your application, the defined structure is more than one label, that is, there are multiple vanishing points, as shown in. The min-cut of this graph is multi-way, and the solution process is a NP-problem (Boykov[3] in his thesis is detailed proof). For example, stereo matching in the disparity, Image restoration intensity and so on, its essence is a multi-label optimization problem. While some methods can artificially transform them into 2-label, this limits the definition of energy functions to a large extent. The

Boykov[3] proposes two algorithms, which can approximate the optimal solution of muli-label problem in polynomial time, and gives the detailed proof and the Optimality property discussion of the two algorithms. This is an article worth reading. Both of these methods are looking for the local minima, which ultimately makes it impossible for any pixel in the graph to change its label to produce a better solution. In each iteration, the two methods perform move optimizations in the form of α-expansion and α-β-swap , respectively. α-expansion move refers to extending the Α-label area so that the points of the original label belong to Alpha ; α-β-swap move is for α-label and Β-label regions so that the label of some of these points changes from α to beta or vice versa . each iteration is a 2-label optimization process, forming a plot with the α and non-alpha as the vanishing Point, and a graph with the α and beta as the vanishing point, searching for the optimal cut, reforming the label, and approaching the optimal solution. α-expansion requires that smoothing items satisfy the Tri-Edge theorem, while α-β-swap can be used for any smoothing item definition, but α-expansion has a strict optimality property bound, It does not produce too bad results, so it is used more often.

Dynamic Graph Cut:
The dynamic graph refers to a sequence of graphs, which will maintain a smooth transition in the sequence, so is it possible to modify the energy of the changed pixel points on the basis of the residual graph on the previous graph to solve them quickly? Dynamic graph cut does not seek the optimal solution, but rather the fast solution of suboptimal. KOHLI[12] Use the re-parametric graph (graph reparameterization) method to modify the dynamic change of the value, and maintain the capacity, flow and other basic constraints, and then directly get suboptimal solution. This approach can tolerate a small number of side changes and a small number of arbitrary node topologies, but as with all other dynamic graph cut algorithms, a small amount, which is a slight temporal variation, is the precondition. It is mainly applied to video-related visual methods such as segmentation.

Bibliography:
[1] L. Ford, D. Fulkerson.flows in Networks. Princeton University Press, 1962.
[2] Andrew v. Goldberg, Robert E. Tarjan.A New Approach to the Maximum-flow problem. In Journal of the Association for Computing Machinery, 35 (4): 921–940, October 1988.
[3] Y. Boykov, v. Kolmogorov.An experimental Comparison of Min-cut/max-flow algorithms for energy minimization in Vision. In IEEE transactions on Pattern Analysis and Machine Intelligence (Pami), volume, page 1124-1137, 2004.
[4] v. Kolmogorov, R. Zabih.What energy Functions Can minimized via Graph Cuts?In IEEE transactions on Pattern Analysis and Machine Intelligence (Pami), Volume, No.2, page 147-159, 2004.
[5] v. Kolmogorov, R. Zabih.multi-camera Scene Reconstruction via Graph Cuts. In European Conference to Computer Vision (ECCV), May 2002 (best paper).
[6] Y. Boykov, O. Veksler and R. Zabih.Faster Approximate energy minimization via graph cuts. In IEEE transactions-on-Pattern Analysis and Machine Intelligence (Pami), Volume, No. One, page 1-18, 2001.
[7] S. Roy, I. Cox.A Maximum-flow Formulation of the N-camera stereo correspondence problem. In international Conference on Computer Vision (ICCV), 1998.
[8] v. Vineet, P. J. Narayanan.CUDA cuts:fast Graph Cuts on the GPU. IN:CVPR Workshop on the Visual computer Vision on GPUs, 2008.
[9] v. Kwatra, A. Schodl, I. Essa, G. Turk and A. Bobick.graphcut textures:image and Video Synthesis Using Graph Cuts. In SIGGRAPH 2003, pp. 277-286.
[J] A. Blum, J. Lafferty, M.R. Rwebangira and R. Reddy.semi-supervised Learning Using randomized mincuts. In Proceedings of the 21st International Conference on Machine Learning (ICML), Banff, Canada 2004.
S. Z. Li,Markov Random Field Modeling in computer Vision, Springer Verlag, 1995.
P. Kohli and P. H. S. Torr.Dynamic graph cuts for efficient inference in Markov random fields. IEEE Trans. Pattern Anal. Mach. Intell. (Pami), 29 (12): 2079–2088, 2007.

Graph Cut and its application in computer Vision

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.