Skip to content

Commit 339bf75

Browse files
committed
first commit
0 parents  commit 339bf75

File tree

378 files changed

+92386
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

378 files changed

+92386
-0
lines changed

3rd/atk-1.32.0.tar.bz2

672 KB
Binary file not shown.

3rd/cairo-1.8.0.tar.gz

5.4 MB
Binary file not shown.

3rd/gettext-0.14.3.tar.gz

6.67 MB
Binary file not shown.

3rd/glib-2.21.5.tar.gz

7.39 MB
Binary file not shown.

3rd/gtk+-2.18.0.tar.gz

26.5 MB
Binary file not shown.

3rd/gtkimageview-1.6.4.tar.gz

1.1 MB
Binary file not shown.

3rd/pango-1.28.0.tar.gz

2.03 MB
Binary file not shown.

3rd/pixman-0.12.0.tar.gz

446 KB
Binary file not shown.

3rd/tiff-3.9.4.zip

1.73 MB
Binary file not shown.

AGPL

+665
Large diffs are not rendered by default.

LICENSE

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
2+
Copyright (C) 2012 Joseph Lim <[email protected]>
3+
Copyright (C) 2012 Pablo Arbelaez <[email protected]>
4+
5+
This program is free software: you can redistribute it and/or modify
6+
it under the terms of the GNU Affero General Public License as published by
7+
the Free Software Foundation, either version 3 of the License, or
8+
(at your option) any later version.
9+
10+
This program is distributed in the hope that it will be useful,
11+
but WITHOUT ANY WARRANTY; without even the implied warranty of
12+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13+
GNU Affero General Public License for more details.
14+
15+
You should have received a copy of the GNU Affero General Public License
16+
along with this program. If not, see <http://www.gnu.org/licenses/>.

README.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
TEXTON SVM
2+
==========
3+
4+
Experimental Evaluation of Support Vector Machine-based and Correlation-based Approaches to Automatic Particle Selection
5+
Pablo Arbelaez, Bong-Gyoon Han, Dieter Typke, Joseph J. Lim, Robert M. Glaeser, Jitendra Malik.
6+
Journal of Structural Biology 2011. doi:10.1016/j.jsb.2011.05.017.
7+

easy_install

+116
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
set -e
2+
3+
TMP_DIR=`readlink -f $0`
4+
TEXTONSVM_DIR=`dirname $TMP_DIR`
5+
6+
# LIBTIFF
7+
cd $TEXTONSVM_DIR/3rd
8+
unzip $TEXTONSVM_DIR/3rd/tiff-3.9.4.zip
9+
cd tiff-3.9.4
10+
./configure --prefix=$TEXTONSVM_DIR/tools/libtiff
11+
make
12+
make install
13+
14+
# gettext
15+
#cd $TEXTONSVM_DIR/3rd
16+
#tar -xvf gettext-0.14.3.tar.gz
17+
#cd gettext-0.14.3
18+
#./configure --prefix=$TEXTONSVM_DIR/tools/gettext
19+
#make
20+
#make install
21+
22+
# glib
23+
PKG_CONFIG_PATH=
24+
LD_LIBRARY_PATH=$TEXTONSVM_DIR/tools/libtiff/lib
25+
cd $TEXTONSVM_DIR/3rd
26+
tar -xvf glib-2.21.5.tar.gz
27+
cd glib-2.21.5
28+
./configure --prefix=$TEXTONSVM_DIR/tools/glib
29+
make
30+
make install
31+
32+
33+
# pixman
34+
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$TEXTONSVM_DIR/tools/glib/lib/pkgconfig
35+
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TEXTONSVM_DIR/tools/glib/lib
36+
PATH=$PATH:$TEXTONSVM_DIR/tools/glib/bin
37+
export PKG_CONFIG_PATH LD_LIBRARY_PATH PATH
38+
cd $TEXTONSVM_DIR/3rd
39+
tar -xvf pixman-0.12.0.tar.gz
40+
cd pixman-0.12.0
41+
./configure --prefix=$TEXTONSVM_DIR/tools/pixman --disable-gtk
42+
make
43+
make install
44+
45+
# cairo
46+
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$TEXTONSVM_DIR/tools/pixman/lib/pkgconfig
47+
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TEXTONSVM_DIR/tools/pixman/lib
48+
export PKG_CONFIG_PATH LD_LIBRARY_PATH
49+
cd $TEXTONSVM_DIR/3rd
50+
tar -xvf cairo-1.8.0.tar.gz
51+
cd cairo-1.8.0
52+
./configure --prefix=$TEXTONSVM_DIR/tools/cairo
53+
#--disable-png --enable-svg=no
54+
make
55+
make install
56+
57+
# pango
58+
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$TEXTONSVM_DIR/tools/cairo/lib/pkgconfig
59+
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TEXTONSVM_DIR/tools/cairo/lib
60+
export PKG_CONFIG_PATH LD_LIBRARY_PATH
61+
cd $TEXTONSVM_DIR/3rd
62+
tar -xvf pango-1.28.0.tar.gz
63+
cd pango-1.28.0
64+
./configure --prefix=$TEXTONSVM_DIR/tools/pango
65+
make
66+
make install
67+
68+
# atk
69+
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$TEXTONSVM_DIR/tools/pango/lib/pkgconfig
70+
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TEXTONSVM_DIR/tools/pango/lib
71+
export PKG_CONFIG_PATH LD_LIBRARY_PATH
72+
cd $TEXTONSVM_DIR/3rd
73+
tar -xvf $TEXTONSVM_DIR/3rd/atk-1.32.0.tar.bz2
74+
cd atk-1.32.0
75+
./configure --prefix=$TEXTONSVM_DIR/tools/atk
76+
make
77+
make install
78+
79+
# gtk
80+
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$TEXTONSVM_DIR/tools/atk/lib/pkgconfig
81+
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TEXTONSVM_DIR/tools/atk/lib
82+
export PKG_CONFIG_PATH LD_LIBRARY_PATH
83+
cd $TEXTONSVM_DIR/3rd
84+
tar -xvf $TEXTONSVM_DIR/3rd/gtk+-2.18.0.tar.gz
85+
cd gtk+-2.18.0
86+
./configure --prefix=$TEXTONSVM_DIR/tools/gtk --without-libpng
87+
make
88+
make install
89+
90+
# gtkimageview
91+
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$TEXTONSVM_DIR/tools/gtk/lib/pkgconfig
92+
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TEXTONSVM_DIR/tools/gtk/lib
93+
export PKG_CONFIG_PATH LD_LIBRARY_PATH
94+
cd $TEXTONSVM_DIR/3rd
95+
tar -xvf $TEXTONSVM_DIR/3rd/gtkimageview-1.6.4.tar.gz
96+
cd gtkimageview-1.6.4
97+
./configure --prefix=$TEXTONSVM_DIR/tools/gtkimageview
98+
make
99+
make install
100+
101+
102+
# textonsvm_setup
103+
cd $TEXTONSVM_DIR
104+
echo 'TEXTONSVM_DIR='$TEXTONSVM_DIR >> textonsvm_setup
105+
106+
filename="textonsvm_setup.tmp"
107+
while read line
108+
do
109+
echo $line >> textonsvm_setup
110+
done <$filename
111+
112+
# final make
113+
cd $TEXTONSVM_DIR
114+
source ./textonsvm_setup
115+
cd src
116+
make

src/Makefile

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
.PHONY: all
2+
all:
3+
ifdef TEXTONSVM_BIN_DIR
4+
make -C input
5+
make -C output
6+
make -C backend
7+
make -C "backend/textonsvm"
8+
else
9+
@echo ERROR: TEXTONSVM_BIN_DIR is not initialized. Check [TEXTONSVM_DIR/textonsvm_setup];
10+
@exit 2;
11+
endif
12+
13+
.PHONY: clean
14+
clean:
15+
make -r -C input clean
16+
make -r -C output clean
17+
make -r -C backend clean
18+
make -r -C "backend/textonsvm" clean

src/backend/Makefile

+52
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
include Rules.make
2+
3+
.PHONY: default
4+
default: all
5+
6+
.PHONY: all
7+
all: src test
8+
9+
.PHONY: world
10+
world: all check_world
11+
12+
.PHONY: src
13+
src:
14+
@$(MAKE) -r -C $(src_dir) all
15+
16+
.PHONY: test
17+
test: src
18+
@$(MAKE) -r -C $(test_dir) all
19+
20+
.PHONY: test_results
21+
test_results:
22+
@$(MAKE) -r -C $(test_dir) test_results_all
23+
24+
.PHONY: test_results_world
25+
test_results_world: test
26+
@$(MAKE) -r -C $(test_dir) test_results_all
27+
28+
.PHONY: check
29+
check:
30+
@$(MAKE) -r -C $(test_dir) check_all
31+
32+
.PHONY: check_world
33+
check_world: test_results_world
34+
@$(MAKE) -r -C $(test_dir) check_all
35+
36+
.PHONY: matlab
37+
matlab:
38+
@$(MAKE) -r -C $(matlab_dir) all
39+
40+
.PHONY: doc
41+
doc:
42+
@$(MAKE) -r -C $(doc_dir) all
43+
44+
.PHONY: doc_clean
45+
doc_clean:
46+
@$(MAKE) -r -C $(doc_dir) clean_all
47+
48+
.PHONY: clean
49+
clean:
50+
@$(MAKE) -r -C $(src_dir) clean_all
51+
@$(MAKE) -r -C $(test_dir) clean_all
52+
@$(MAKE) -r -C $(matlab_dir) clean_all

src/backend/Rules.make

+84
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
#############################################################################
2+
# Project directory structure.
3+
#############################################################################
4+
5+
# build scripts directory
6+
build_scripts_dir := scripts/build
7+
8+
# directory layout
9+
bin_dir := bin
10+
depend_dir := depend
11+
include_dir := include
12+
src_dir := src
13+
test_dir := test
14+
matlab_dir := matlab
15+
doc_dir := doc
16+
17+
#############################################################################
18+
# C++ compilation settings.
19+
#############################################################################
20+
21+
# compiler
22+
CXX := g++
23+
24+
# compilation settings - libraries to link
25+
CXX_LINK := -ljpeg -lpng
26+
27+
# compilation settings - warning flags
28+
CXX_WARN_BASIC := -ansi -Wall -Wno-long-long
29+
CXX_WARN_EXTRA := -Wundef -Wpointer-arith -Wold-style-cast \
30+
-Woverloaded-virtual -Wsign-promo
31+
CXX_WARN := $(CXX_WARN_BASIC) $(CXX_WARN_EXTRA)
32+
33+
# compilation settings - build flags
34+
CXX_BUILD := -pthread -fexceptions -fPIC -O3 -rdynamic
35+
36+
# compilation settings - all flags
37+
CXX_FLAGS := $(CXX_WARN) $(CXX_BUILD)
38+
39+
# compilation settings - linker flags
40+
CXX_LDFLAGS := $(CXX_FLAGS) $(CXX_LINK)
41+
42+
#############################################################################
43+
# Matlab mex file compilation settings (only used if building mex files).
44+
#############################################################################
45+
46+
# matlab mex file compilation settings - matlab path
47+
MATLAB_PATH := /usr/local/matlab/matlab-r2007a
48+
49+
# matlab mex file compilation settings - matlab architecture (32-bit machines)
50+
#MATLAB_ARCH := glnx86
51+
#MEX_EXTN := mexglx
52+
53+
# matlab mex file compilation settings - matlab architecture (64-bit machines)
54+
MATLAB_ARCH := glnxa64
55+
MEX_EXTN := mexa64
56+
57+
# matlab mex file compilation settings - include path for mex header files
58+
MEX_INCLUDE_PATH := $(MATLAB_PATH)/extern/include
59+
60+
# matlab mex file compilation settings - libraries to link
61+
MEX_LINK := $(CXX_LINK) -lmx -lmex -lmat
62+
63+
# matlab mex file compilation settings - warning flags
64+
MEX_WARN := $(CXX_WARN)
65+
66+
# matlab mex file compilation settings - build flags
67+
MEX_BUILD := $(CXX_BUILD) -DMATLAB_MEX_FILE -D_GNU_SOURCE -DNDEBUG
68+
69+
# matlab mex file compilation settings - all flags
70+
MEX_FLAGS := $(MEX_WARN) $(MEX_BUILD)
71+
72+
# matlab mex file compilation settings - linker flags
73+
MEX_LDFLAGS := \
74+
$(MEX_FLAGS) -shared \
75+
-Wl,--version-script,"$(MATLAB_PATH)/extern/lib/$(MATLAB_ARCH)/mexFunction.map" \
76+
-Wl,--rpath-link,"$(MATLAB_PATH)/bin/$(MATLAB_ARCH)" \
77+
-L"$(MATLAB_PATH)/bin/$(MATLAB_ARCH)" $(MEX_LINK)
78+
79+
#############################################################################
80+
# Documentation build settings (only used if generating documentation).
81+
#############################################################################
82+
83+
# doxygen c++ source code documentation generator
84+
DOXYGEN := doxygen

0 commit comments

Comments
 (0)