[go: up one dir, main page]

Menu

[r303]: / release-3 / docs / wiki_main  Maximize  Restore  History

Download this file

101 lines (57 with data), 3.7 kB

### Description

COCOLIB is a library for continuous global optimization, focusing on the minimization of functionals of the type

E(u) = J(u) + F(u)

where u is an image (i.e. vector-valued function on an interval), J is a convex and closed regularizer, and F a closed and usually also convex data term.

The complete overview can be found on the [project home page](https://sourceforge.net/p/cocolib/home/Home/).



<br><br>
### Requirements and support

All algorithms are implemented in C++ using CUDA, and have been tested on Ubuntu 11.04. The code is provided as a service to the image processing community and "as is", without any support beyond the documentation presented here. If you run into a problem, please ask in the forum for help. If I find the time, I will try to be of assistance.

You will need the following installed on your system:

- CUDA capable graphics card
- Latest nVidia driver, CUDA toolkit (SDK is not necessary), compiler 'nvcc' must be in shell search path
- Qt library (with development support, Ubuntu package 'libqt4-dev')
- GNU scientific library (with development support, Ubuntu package 'libgsl0-dev')


<br><br>
### Downloading the library

Current release tarball:

[[download_button]]


<br><br>
Latest development version via *subversion*:

~~~~~~~~~~~~~~~~~~~
svn checkout --username=goldluecke https://svn.code.sf.net/p/cocolib/code/trunk cocolib-dev
~~~~~~~~~~~~~~~~~~~

<br><br>
### Building the library and examples

- Download and unpack the desired release of the library
- Change to project directory
- In a shell, type

~~~~~~~~~~~~~~~~~~~~~~~~~~~~
qmake cocolib.pro
make
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

If everything works fine, the library *libcocolib.a* will be built in the folder *cocolib*, and the command line tool *coco-ip* will be built in the folder *examples*.

In case there were errors, please check out the [common build problems](Troubleshooting) here, before reporting the problem on the forum.



<br><br>
### Getting started with the tool: running the examples

In order to test if the command line tool was built correctly, try to

- change to the "examples" subdirectory.
- View an example configuration file with

        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        cat example_configs/config_tv_denoising
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

- Run the command line tool using the example configuration via

        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        ./coco-ip -config example_configs/config_tv_denoising
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

- You can override parameters from the configuration file by specifying them after the filename in the command line

        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        ./coco-ip -config example_configs/config_tv_denoising -lambda 10.0
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


Running the above example should produce output in the subdirectory "out/tv/denoising/".

For a complete list of the command line options and further examples, please refer on the documentation of the [command line tool](Command Line Tool).



<br><br>
### Getting started with the code: library documentation

A brief outline of the library framework is available [here](Library), but other than that you will have to look at the code.



<br><br>
### Disclaimer

The library is research code. In particular, it has not been tested except for a certain small range of use cases, and might fail spectacularly if provided with unexpected parameters (including completely crashing your system). Do not use in production environments unless you add lots of safeguards, in which case I'm happy if you can contribute back to the repository (contact me for access).