DGM library v.1.7.0 has been just released
This is our grand winter release DGM 1.7 which incorporates Complete (dense) graphical models, supports recently released OpenCV 4.0 and now available also for Linux (Ubuntu) operating system. The library has also undergone massive refactoring with emphasis on simplifying the user interface. The library is now easier to use than ever before.
Classical CRF models are composed of unary potentials on individual observations and pairwise potentials on neighboring observations. The resulting adjacency CRF structure is limited in its ability to model long-range connections within the observations and generally results in excessive smoothing of observed object boundaries. Dense CRF establishes pairwise potentials on all pairs of observations, enabling greatly refined labeling. The main challenge is the size of the model. DGM library now includes efficient inference algorithm for dense CRF models in which the pairwise edge potentials are defined by a linear combination of Gaussian kernels in an arbitrary feature space. The resulting approximate inference algorithm is sub-linear in the number of edges in the model [1].
In this release we introduce two powerful tools for simplifying work with graphical models:
- Graph extensions, which significantly simplify building and filling the 2D graphical models used for image classification. In addition, with help of the pairwise graph extension the training of the edges was also simplified in terms of the required user code.
- Factory methods, which allow for creating objects of a library in a way such that it doesn’t have tight coupling with the class hierarchy of the library. Such factories allow you to switch from one model to another (pairwise graph to dense, Bayes classifier to neural network classifier, etc.) with changing just one argument – the flag of the factory method function.
Our library was conceived primarily as an educational project – a useful tool for university students and researchers who experiment with various machine learning algorithms for semantic segmentation and labeling of images. That is why from the very first versions of the DGM library we paid a lot of attention to the efficient and qualitative evaluation of algorithms and results obtained with the help of our library. Since students and researchers often have situations when they have to change the library code for their specific tasks, we decided that it was time to review the quality of our code. Starting from this release we incorporate an automatic code review solution CodeFactor and try to keep our current grade score A (97,6%) at the same level. Together with the in-depth documentation this will allow our users easily go into the code and understand the implemented algorithms fast.
Finally, we have changed all the demo code snippets to illustrate the benefits of factory methods and graph extensions and added two more tutorials: one for dense CRFs and another – for the control model parameters training. Every tutorial includes a ready-to-use demo application within the library. These demo applications are ideal base for starting your own project and starting to use our DGM library.
[1] P. Krähenbühl and V. Koltun Efficient Inference in Fully Connected CRFs with Gaussian Edge Potentials