-
Notifications
You must be signed in to change notification settings - Fork 25
/
setup.py
64 lines (58 loc) · 2.37 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
from distutils.core import setup
from distutils.extension import Extension
from distutils.sysconfig import get_python_inc
import sys
import os.path
import platform
import numpy
np_inc = os.path.join(numpy.__path__[0], 'core', 'include')
# use additional compiler flags: "-ffast-math" "-g"
# FIXME this only works for EPD?
if platform.system() == "Windows":
lib_path = "C:\Python26\PCbuild"
else:
lib_path = "/usr/lib"
setup(
name = "nut.externals.bolt",
ext_modules = [
Extension("nut.externals.bolt.trainer.sgd",
["nut/externals/bolt/trainer/sgd.c"],
include_dirs=[np_inc],
extra_link_args=["-O3"],
library_dirs=[lib_path,],
extra_compile_args=["-O3", "-g"]
),
Extension("nut.externals.bolt.trainer.avgperceptron",
["nut/externals/bolt/trainer/avgperceptron.c"],
include_dirs=[np_inc],
extra_link_args=["-O3"],
library_dirs=[lib_path,],
extra_compile_args=["-O3", "-g"]
),
Extension("nut.externals.bolt.trainer.maxent",
["nut/externals/bolt/trainer/maxent.c"],
include_dirs=[np_inc],
extra_link_args=["-O3"],
library_dirs=[lib_path,],
extra_compile_args=["-O3", "-g"]
),
],
version = "0.1",
description="Natural language Understanding Toolkit (NUT)",
author='Peter Prettenhofer',
author_email='[email protected]',
url = 'http://www.github.com/pprett/nut/',
license = 'new BSD',
classifiers =
['Intended Audience :: Science/Research',
'Intended Audience :: Developers',
'License :: OSI Approved',
'Programming Language :: C',
'Programming Language :: Python',
'Topic :: Scientific/Engineering',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX',
'Operating System :: Unix',
'Operating System :: MacOS'
]
)