Skip to content

Commit c32bbc5

Browse files
committed
* Initial commit.
0 parents  commit c32bbc5

14 files changed

+5743
-0
lines changed

.gitignore

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
*.o
2+
*.mex
3+
*.mexa64
4+
latex
5+
test
6+
dali.pdf

Doxyfile

+1,551
Large diffs are not rendered by default.

Makefile

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
2+
3+
USE_PTHREADS := true
4+
5+
NAME := dali
6+
7+
CFILES := test.c dali.c dali_dist.c dali_mesh.c
8+
9+
CFLAGS_FFTW3 := $(shell pkg-config --cflags fftw3)
10+
LDFLAGS_FFTW3 := $(shell pkg-config --libs fftw3)
11+
CFLAGS_ARPACK := $(shell pkg-config --cflags arpack)
12+
LDFLAGS_ARPACK := $(shell pkg-config --libs arpack)
13+
14+
CFLAGS := -g3 -D_GNU_SOURCE=1 -W -Wall -Wextra -Wunused -Wshadow -Wpointer-arith -Wmissing-prototypes -Winline -Wcast-align -Wmissing-declarations -Wredundant-decls -Wno-long-long -Wcast-align $(CFLAGS_FFTW3) $(CFLAGS_ARPACK)
15+
LDFLAGS := $(LDFLAGS_FFTW3) -lceigs $(LDFLAGS_ARPACK) -lm -lcxsparse -lumfpack -lvl #-lcblas -lf77blas -latlas
16+
17+
ifeq ($(USE_PTHREADS),true)
18+
CFLAGS += -DHAVE_PTHREADS=1
19+
LDFLAGS += -lpthread
20+
endif
21+
22+
#CFLAGS += -DDEBUG
23+
24+
.PHONY: all octave docs clean
25+
26+
all: octave test
27+
28+
test: dali.h $(CFILES)
29+
$(CC) $(CFLAGS) $(CFILES) -o $@ $(LDFLAGS)
30+
31+
octave:
32+
(cd octave; $(MAKE))
33+
34+
docs:
35+
doxygen
36+
(cd latex; $(MAKE))
37+
cp latex/refman.pdf $(NAME).pdf
38+
39+
clean:
40+
$(RM) test

README.md

+141
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,141 @@
1+
DaLI: Deformation and Light Invariant Descriptor
2+
================================================
3+
4+
5+
OVERVIEW
6+
--------
7+
8+
This code provides an implementation of the research paper:
9+
10+
```
11+
DaLI: Deformation and Light Invariant Descriptor
12+
Edgar Simo-Serra, Carme Torras, Francesc Moreno-Noguer
13+
International Journal of Computer Vision (IJCV), 2015
14+
```
15+
16+
This allows local representation of image patches in such a way that they can be compared with strong invariance to both deformation and illumination.
17+
18+
The core of the code is written in C and is meant to be embedded in applications. It should be also possible to compile as a library and installed at a system level.
19+
20+
21+
License
22+
-------
23+
24+
```
25+
Copyright (C) <2011-2015> <Francesc Moreno-Noguer, Edgar Simo-Serra>
26+
27+
This program is free software: you can redistribute it and/or modify
28+
it under the terms of the version 3 of the GNU General Public License
29+
as published by the Free Software Foundation.
30+
31+
This program is distributed in the hope that it will be useful, but
32+
WITHOUT ANY WARRANTY; without even the implied warranty of
33+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
34+
General Public License for more details.
35+
You should have received a copy of the GNU General Public License
36+
along with this program. If not, see <http://www.gnu.org/licenses/>.
37+
38+
Edgar Simo-Serra, Institut de Robotica i Informatica Industrial (CSIC/UPC), January 2015.
39+
[email protected], http://www-iri.upc.es/people/esimo/
40+
```
41+
42+
43+
Installation
44+
------------
45+
46+
The software depends on the [ceigs library](https://github.com/bobbens/ceigs) which provides an elegant C frontend to the [ARPACK library](http://www.caam.rice.edu/software/ARPACK/). Upon installing the ceigs library it should be possible to compile both the test application and the matlab/octave by simpling running make:
47+
48+
```
49+
$ make
50+
```
51+
52+
53+
Usage
54+
-----
55+
56+
The descriptor can be used both from octave (theoretically also matlab) and C. For an example of usage from C see the "test.c" file. As it should be compiled you can also run it by doing
57+
58+
```
59+
$ ./test
60+
```
61+
62+
You should get an output as the following:
63+
64+
```
65+
Processing point 9 x 8...
66+
Computing mesh...
67+
Computing Laplace-Beltrami...
68+
Computing EigenVectors...
69+
Computing HKS...
70+
Computing HKS-SI...
71+
Done!
72+
Processing point 310 x 0...
73+
Computing mesh...
74+
Computing Laplace-Beltrami...
75+
Computing EigenVectors...
76+
Computing HKS...
77+
Computing HKS-SI...
78+
Done!
79+
80+
...
81+
82+
2 vs 6: 3967.624281
83+
3 vs 4: 1897.634498
84+
3 vs 5: 2542.110789
85+
3 vs 6: 2476.372066
86+
4 vs 5: 2614.770836
87+
4 vs 6: 2631.432283
88+
5 vs 6: 956.697412
89+
```
90+
91+
Additionally it is possible to run the application from octave. Currently matlab is not supported due to a library conflict, but in theory it should also be possible. To try the octave version from the "octave/" directory launch octave and run "test" as such:
92+
93+
```
94+
>> test
95+
```
96+
97+
You should get an output such as:
98+
99+
```
100+
Processing point 9 x 8...
101+
Computing mesh...
102+
Computing Laplace-Beltrami...
103+
Computing EigenVectors...
104+
Computing HKS...
105+
Computing HKS-SI...
106+
Done!
107+
108+
...
109+
110+
3 vs 4: 2.238990
111+
3 vs 5: 2.119231
112+
3 vs 6: 2.050154
113+
4 vs 5: 3.051406
114+
4 vs 6: 3.014572
115+
5 vs 6: 0.891666
116+
```
117+
118+
If you use this code please cite:
119+
120+
```
121+
@Article{SimoSerraIJCV2015,
122+
author = {Edgar Simo-Serra and Carme Torras and Francesc Moreno Noguer},
123+
title = {{DaLI: Deformation and Light Invariant Descriptor}},
124+
journal = {International Journal of Computer Vision (IJCV)} volume = {1},
125+
pages = {1--1},
126+
year = 2015,
127+
}
128+
```
129+
130+
Known Issues
131+
------------
132+
133+
Currently it is not possible to run in matlab due to library conflict issues. However, it is possible to run it in octave or integrate it into any C application.
134+
135+
136+
Changelog
137+
---------
138+
139+
January 2015: Initial version 1.0 release
140+
141+

0 commit comments

Comments
 (0)