forked from kanshao/bbmd
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
55 lines (47 loc) · 1.44 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
import re
import os
import sys
from setuptools import setup, find_packages
def get_version():
regex = r"^__version__ = '(.*)'$"
with open('bbmd/__init__.py', 'r') as f:
text = f.read()
return re.findall(regex, text, re.MULTILINE)[0]
if sys.argv[-1] == 'publish_test':
os.system('python setup.py sdist upload -r https://testpypi.python.org/pypi')
os.system('python setup.py bdist_wheel upload -r https://testpypi.python.org/pypi')
sys.exit()
if sys.argv[-1] == 'publish_production':
os.system('python setup.py sdist upload')
os.system('python setup.py bdist_wheel upload')
sys.exit()
def readme():
with open('README.rst') as f:
return f.read()
setup(
name='bbmd',
version=get_version(),
description='Bayesian benchmark dose (BBMD) modeling using PyStan',
long_description=readme(),
url='https://bitbucket.org/geniussk/bayesian-bmd-stats',
author='Kan Shao, Andy Shapiro',
author_email='[email protected]',
license='TBD',
packages=find_packages(exclude=['tests']),
install_requires=[
'numpy>=1.12.0',
'scipy>=0.19.0',
'pystan==2.14.0.0',
'matplotlib>=1.4.3, <1.5',
'python-docx>=0.8.6',
'pandas>=0.19.2',
'openpyxl>=2.4.5',
],
include_package_data=True,
zip_safe=False,
entry_points={
'console_scripts': [
'compile_stan_models = bbmd.compilation:compile_stan',
]
},
)