setup.py 4.13 KB
Newer Older
André Anjos's avatar
André Anjos committed
1
2
3
4
5
#!/usr/bin/env python
# vim: set fileencoding=utf-8 :
# Andre Anjos <andre.anjos@idiap.ch>
# Mon 16 Apr 08:18:08 2012 CEST

6
7
bob_packages = ['bob.core', 'bob.io.base', 'bob.sp', 'bob.math', 'bob.learn.activation', 'bob.learn.linear']

André Anjos's avatar
André Anjos committed
8
from setuptools import setup, find_packages, dist
9
dist.Distribution(dict(setup_requires=['bob.extension>=2.0.7', 'bob.blitz'] + bob_packages))
10
from bob.blitz.extension import Extension, Library, build_ext
André Anjos's avatar
André Anjos committed
11

André Anjos's avatar
André Anjos committed
12
13
14
from bob.extension.utils import load_requirements
build_requires = load_requirements()

15
16
17
# Define package version
version = open("version.txt").read().rstrip()

18
packages = ['boost']
19
boost_modules = ['system']
André Anjos's avatar
André Anjos committed
20
21
22

setup(

23
    name='bob.learn.em',
André Anjos's avatar
André Anjos committed
24
    version=version,
25
26
    description='Bindings for emelaneous machines and trainers of Bob',
    url='http://github.com/bioidiap/bob.learn.em',
André Anjos's avatar
André Anjos committed
27
28
29
30
31
32
33
34
    license='BSD',
    author='Andre Anjos',
    author_email='andre.anjos@idiap.ch',

    long_description=open('README.rst').read(),

    packages=find_packages(),
    include_package_data=True,
Amir's avatar
Amir committed
35
    zip_safe=False,
André Anjos's avatar
André Anjos committed
36

37
38
    setup_requires = build_requires,
    install_requires = build_requires,
André Anjos's avatar
André Anjos committed
39

40

André Anjos's avatar
André Anjos committed
41
42

    ext_modules = [
43
      Extension("bob.learn.em.version",
André Anjos's avatar
André Anjos committed
44
        [
45
          "bob/learn/em/version.cpp",
46
47
48
49
50
51
52
        ],
        bob_packages = bob_packages,
        packages = packages,
        boost_modules = boost_modules,
        version = version,
      ),

53
      Library("bob.learn.em.bob_learn_em",
54
        [
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
          "bob/learn/em/cpp/Gaussian.cpp",
          "bob/learn/em/cpp/GMMMachine.cpp",
          "bob/learn/em/cpp/GMMStats.cpp",
          "bob/learn/em/cpp/IVectorMachine.cpp",
          "bob/learn/em/cpp/KMeansMachine.cpp",
          "bob/learn/em/cpp/LinearScoring.cpp",
          "bob/learn/em/cpp/PLDAMachine.cpp",
          "bob/learn/em/cpp/ZTNorm.cpp",

          "bob/learn/em/cpp/FABase.cpp",
          "bob/learn/em/cpp/JFABase.cpp",
          "bob/learn/em/cpp/ISVBase.cpp",
          "bob/learn/em/cpp/JFAMachine.cpp",
          "bob/learn/em/cpp/ISVMachine.cpp",

          "bob/learn/em/cpp/FABaseTrainer.cpp",
          "bob/learn/em/cpp/JFATrainer.cpp",
          "bob/learn/em/cpp/ISVTrainer.cpp",

          "bob/learn/em/cpp/EMPCATrainer.cpp",
          "bob/learn/em/cpp/GMMBaseTrainer.cpp",
          "bob/learn/em/cpp/IVectorTrainer.cpp",
          "bob/learn/em/cpp/KMeansTrainer.cpp",
          "bob/learn/em/cpp/MAP_GMMTrainer.cpp",
          "bob/learn/em/cpp/ML_GMMTrainer.cpp",
          "bob/learn/em/cpp/PLDATrainer.cpp",
81
82
        ],
        bob_packages = bob_packages,
André Anjos's avatar
André Anjos committed
83
        packages = packages,
84
        boost_modules = boost_modules,
André Anjos's avatar
André Anjos committed
85
        version = version,
86
87
      ),

88
      Extension("bob.learn.em._library",
André Anjos's avatar
André Anjos committed
89
        [
90
91
92
93
94
95
          "bob/learn/em/gaussian.cpp",
          "bob/learn/em/gmm_stats.cpp",
          "bob/learn/em/gmm_machine.cpp",
          "bob/learn/em/kmeans_machine.cpp",
          "bob/learn/em/kmeans_trainer.cpp",

96
97
          "bob/learn/em/ml_gmm_trainer.cpp",
          "bob/learn/em/map_gmm_trainer.cpp",
98
99
100
101
102
103
104
105

          "bob/learn/em/jfa_base.cpp",
          "bob/learn/em/jfa_machine.cpp",
          "bob/learn/em/jfa_trainer.cpp",

          "bob/learn/em/isv_base.cpp",
          "bob/learn/em/isv_machine.cpp",
          "bob/learn/em/isv_trainer.cpp",
106

107
108
          "bob/learn/em/ivector_machine.cpp",
          "bob/learn/em/ivector_trainer.cpp",
109

110
111
          "bob/learn/em/plda_base.cpp",
          "bob/learn/em/plda_machine.cpp",
112

113
          "bob/learn/em/empca_trainer.cpp",
114

115
          "bob/learn/em/plda_trainer.cpp",
Tiago de Freitas Pereira's avatar
Tiago de Freitas Pereira committed
116

117
          "bob/learn/em/ztnorm.cpp",
Tiago de Freitas Pereira's avatar
Tiago de Freitas Pereira committed
118

119
          "bob/learn/em/linear_scoring.cpp",
120

121
          "bob/learn/em/main.cpp",
André Anjos's avatar
André Anjos committed
122
        ],
123
        bob_packages = bob_packages,
André Anjos's avatar
André Anjos committed
124
        packages = packages,
125
        boost_modules = boost_modules,
André Anjos's avatar
André Anjos committed
126
        version = version,
127
128
129
130
131
132
      ),
    ],

    cmdclass = {
      'build_ext': build_ext
    },
André Anjos's avatar
André Anjos committed
133
134

    classifiers = [
135
      'Framework :: Bob',
André Anjos's avatar
André Anjos committed
136
137
138
139
140
141
142
      'Development Status :: 3 - Alpha',
      'Intended Audience :: Developers',
      'License :: OSI Approved :: BSD License',
      'Natural Language :: English',
      'Programming Language :: Python',
      'Programming Language :: Python :: 3',
      'Topic :: Software Development :: Libraries :: Python Modules',
143
    ],
André Anjos's avatar
André Anjos committed
144

145
  )