-
Notifications
You must be signed in to change notification settings - Fork 116
/
setup.py
79 lines (65 loc) · 2.25 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
try:
from setuptools import setup, Extension
except ImportError:
from distutils.core import setup, Extension
from Cython.Build import cythonize
import numpy as np
import glob
def readme():
with open('README.rst') as f:
text = f.read()
return text
extensions = [
Extension('deepnl/words',
sources=["deepnl/words.pyx", "deepnl/WordsTrainer.cpp"],
include_dirs=[np.get_include(),
"/usr/include/eigen3"],
language="c++",
extra_compile_args=["-fopenmp"]),
Extension('deepnl/hpca',
sources=["deepnl/hpca.pyx", "deepnl/HPCA_impl.cpp"],
include_dirs=[np.get_include(),
"/usr/include/eigen3"],
language="c++",
extra_compile_args=["-std=c++11"],
extra_link_args=["-fopenmp"]),
Extension('deepnl/*',
sources=['deepnl/*.pyx'],
include_dirs=[np.get_include(),
"/usr/include/eigen3"],
language="c++",
extra_compile_args=["-fopenmp"]),
]
setup(
name = "deepnl",
description = "Deep Learning for NLP tasks",
author = "Giuseppe Attardi <[email protected]>",
author_email = "[email protected]",
url = "https://github.com/attardi/deepnl",
license = "GNU GPL",
version = "1.3.18",
platforms = "any",
keywords = " Deep learning "
" Neural network "
" Natural language processing ",
requires = ["numpy (>= 1.9)"],
packages = ["deepnl"],
ext_modules = cythonize(
extensions,
language="c++",
nthreads=4),
scripts = glob.glob("bin/*.py"),
classifiers = [
"Development Status :: 3 - Alpha",
"Environment :: Console",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: GNU General Public License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: Text Processing :: Linguistic",
],
long_description = readme()
)