Skip to content

srinituraga/lua---imgraph

 
 

Repository files navigation

imgraph: a package to create/manipulate graphs on images

This package provides standard functions to create and manipulate edge-weighted graphs of images: create a graph, segment it, compute its watershed, or its connected components...

Install

1/ Torch7 is required:

Dependencies, on Linux (Ubuntu > 9.04):

$ apt-get install gcc g++ git libreadline5-dev cmake wget libqt4-core libqt4-gui libqt4-dev

Dependencies, on Mac OS (Leopard, or more), using Homebrew:

$ brew install git readline cmake wget qt

Then on both platforms:

$ git clone https://github.com/andresy/torch
$ cd torch
$ mkdir build; cd build
$ cmake ..
$ make
$ [sudo] make install

2/ Once Torch7 is available, install this package:

$ [sudo] torch-pkg install imgraph

Use the library

First run torch, and load imgraph:

$ torch
> require 'imgraph'

Once loaded, tab-completion will help you navigate through the library:

> imgraph. + TAB
imgraph.colorize(           imgraph.connectcomponents(  
imgraph.graph(              imgraph.histpooling(        
imgraph.segmentmst(         imgraph.testme(             
imgraph.watershed(          imgraph.gradient(

To get quickly started, run the testme() function:

> imgraph.testme()

which computes a few things on the famous image of Lena:

results

About

A package to deal with graphs built on images.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 90.7%
  • C++ 5.7%
  • Lua 3.3%
  • Objective-C 0.3%