-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathsetup.py
44 lines (42 loc) · 1.69 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
from os import cpu_count
from setuptools import setup
from pathlib import Path
from setuptools import Extension
try:
from Cython.Build import cythonize
extm = cythonize([Extension('mnnpy._utils',
['mnnpy/_utils.pyx'],
extra_compile_args = ['-O2', '-ffast-math', '-march=native', '-fopenmp'],
extra_link_args=['-fopenmp'])])
except ImportError:
print('Building with c.')
extm = [Extension('mnnpy._utils',
['mnnpy/_utils.c'],
extra_compile_args = ['-O2', '-ffast-math', '-march=native', '-fopenmp'],
extra_link_args=['-fopenmp'])]
req_path = Path('requirements.txt')
with req_path.open() as requirements:
requires = [l.strip() for l in requirements]
setup(name='mnnpy',
version='0.1.9.5',
description='Mutual nearest neighbors correction in python.',
long_description='Correcting batch effects in single-cell expression datasets using the mutual nearest neighbors method.',
url='http://github.com/chriscainx/mnnpy',
author='Chris Kang',
author_email='kbxchrs@gmail.com',
license='BSD 3',
packages=['mnnpy'],
install_requires=requires,
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Science/Research',
'Topic :: Scientific/Engineering :: Bio-Informatics',
'License :: OSI Approved :: BSD License',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
python_requires='>=3.4',
py_modules=['irlb', 'mnn', 'utils'],
ext_modules=extm,
zip_safe=False)