Giter Site home page Giter Site logo

caomw / graphcutmex_boykovkolmogorov Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aosokin/graphcutmex_boykovkolmogorov

0.0 1.0 0.0 196 KB

MATLAB wrapper to the max-flow/min-cut algorithm by Boykov and Kolmogorov

License: MIT License

MATLAB 4.91% C++ 94.86% C 0.23%

graphcutmex_boykovkolmogorov's Introduction

This software implements the MATLAB wrapper for Boykov-Kolmogorov max-flow/min-cut algorithm.

Anton Osokin, ([email protected])
19.05.2013
https://github.com/aosokin/graphCutMex_BoykovKolmogorov

Please cite the following paper in any resulting publication:

Yuri Boykov and Vladimir Kolmogorov, An experimental comparison of Min-Cut/Max-Flow algorithms for energy minimization in vision, 
IEEE TPAMI, 26(9):1124-1137, 2004.

PACKAGE
-----------------------------

./graphCutMex.cpp, ./graphCutMex.h - the C++ code of the wrapper

./build_graphCutMex.m - function to build the wrapper

./graphCutMex.m - the description of the implemented function

./example_graphCutMex.m - the example of usage

./maxflow-v3.03.src - C++ code by Vladimir Kolmogorov (the code was slightly modified)
http://pub.ist.ac.at/~vnk/software/maxflow-v3.03.src.zip

./graphCutMex.mexw64 - Win x64 binary file for the MEX-function compiled using MATLAB R2014a + MSVC 2012

./graphCutMex.mexa64 - Linux x64 binary file for the MEX-function compiled using  MATLAB R2012a + gcc-4.4

USING THE CODE
-----------------------------

0) Install MATLAB and one of the supported compilers

1) Run build_graphCutMex.m

2) Run example_graphCutMex.m to check if the code works

The code was tested under 
- Win7-x64 using MATLAB R2014a and MSVC 2012;
- ubuntu-12.04-x64 using MATLAB R2012a and gcc-4.4

OTHER PACKAGES
-----------------------------

* BK max-flow/min-cut algorithm with interface supporting dynamic graph cuts:
https://github.com/aosokin/graphCutDynamicMex_BoykovKolmogorov

If you need to solve many similar graph cut problems in a row consider using dynamic graph cuts.

* IBFS max-flow/min-cut algorithm: https://github.com/aosokin/graphCutMex_IBFS

The IBFS algorithm has polynomial time runtime guarantees. The BK does not.
In my experience BK works faster for graphs built for standard 4(8)-connected grid MRFs.
If the graph becomes more complicated (especially hierarchical) consider trying IBFS instead.

* QPBO algorithm
https://github.com/aosokin/qpboMex

If you need to minimize energy with just a few non-submodular edges try using the QPBO algorithm 

graphcutmex_boykovkolmogorov's People

Contributors

aosokin avatar

Watchers

曹明伟,Mingwei Cao avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.