-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
42 lines (36 loc) · 1.21 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
import os
import re
import numpy as np
from setuptools import Extension, find_packages, setup
def read_version():
with open(os.path.join("optimask", "__init__.py"), "r") as f:
version_file = f.read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]", version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError("Unable to find version string.")
# Read the long description from README.md
with open("README.md", "r") as fh:
long_description = fh.read()
# Setup configuration
setup(
name='optimask',
version=read_version(),
packages=find_packages(),
url='https://optimask.readthedocs.io',
install_requires=['numpy', 'pandas'],
setup_requires=['numpy'],
description="OptiMask: extracting the largest (non-contiguous) submatrix without NaN",
long_description_content_type='text/markdown',
long_description=long_description,
author='Cyril Joly',
license='MIT',
classifiers=['License :: OSI Approved :: MIT License'],
ext_modules=[
Extension(
"optimask.optimask_cython",
sources=["optimask/optimask_cython.c"],
include_dirs=[np.get_include()]
)
]
)