This repository was archived by the owner on Jan 30, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathsetup.py
More file actions
72 lines (60 loc) · 1.84 KB
/
setup.py
File metadata and controls
72 lines (60 loc) · 1.84 KB
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
""" Hidden semi-Markov models with explicit durations in Python.
"""
import glob
import os
from setuptools import find_packages, setup, Extension
SOURCES = (
["hsmmlearn/base.pyx"] + glob.glob('hsmmlearn/_hsmm/src/*.cpp')
)
def get_extension_modules():
# ReadTheDocs has trouble with C extension modules, so don't build the
# Cython modules.
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
if on_rtd:
return []
else:
from Cython.Build import cythonize
extensions = [
Extension("hsmmlearn.base", SOURCES, language="c++")
]
return cythonize(extensions)
CLASSIFIERS = [
"Development Status :: 3 - Alpha",
"License :: OSI Approved",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"Topic :: Software Development",
"Topic :: Scientific/Engineering",
"Programming Language :: Cython",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
]
REQUIREMENTS = [
"cython",
"numpy",
"scipy",
]
DESCRIPTION = __doc__
MAINTAINER = 'Joris Vankerschaver'
MAINTAINER_EMAIL = 'Joris.Vankerschaver@gmail.com'
LICENSE = 'GPL v3'
with open('README.md', encoding="utf-8") as handle:
LONG_DESCRIPTION = handle.read()
setup(
name='hsmmlearn',
ext_modules=get_extension_modules(),
packages=find_packages(include=["hsmmlearn", "hsmmlearn.*"]),
include_package_data=True,
install_requires=REQUIREMENTS,
classifiers=CLASSIFIERS,
version='0.1.0',
description=DESCRIPTION,
long_description=LONG_DESCRIPTION,
maintainer=MAINTAINER,
maintainer_email=MAINTAINER_EMAIL,
license=LICENSE,
)