-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
100 lines (87 loc) · 3.62 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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
#!/usr/bin/env python
"""Description:
Setup script for CRISPResso2 -- Software pipeline for the analysis of genome editing outcomes from deep sequencing data
@status: beta
@version: $Revision$
@author: edilytics
@contact: [email protected]
CRISPResso2 - Kendell Clement and Luca Pinello 2020
Software pipeline for the analysis of genome editing outcomes from deep sequencing data
(c) 2020 The General Hospital Corporation. All Rights Reserved.
"""
from setuptools import setup, Extension
from io import open
# Use build_ext from Cython if found
command_classes = {}
try:
import Cython.Distutils
command_classes['build_ext'] = Cython.Distutils.build_ext
has_cython = True
except:
has_cython = False
ext = '.pyx' if has_cython else '.c'
from numpy import get_include as numpy_get_include
numpy_include_dir = [numpy_get_include()]
import sys
import re
def main():
version = re.search(
r'^__version__\s*=\s*"(.*)"',
open('CRISPResso2/CRISPRessoShared.py').read(),
re.M
).group(1)
ext_modules = [
Extension("CRISPResso2.CRISPRessoCOREResources", ["CRISPResso2/CRISPRessoCOREResources" + ext], include_dirs=numpy_include_dir, extra_compile_args=['-w','-Ofast'] ),
Extension("CRISPResso2.CRISPResso2Align", ["CRISPResso2/CRISPResso2Align" + ext], include_dirs=numpy_include_dir, extra_compile_args=['-w','-Ofast'] ),
]
if has_cython:
from Cython.Build import cythonize
ext_modules = cythonize(ext_modules, language_level="3")
call_root = "CRISPResso"
if "--no_clash_crispresso1" in sys.argv:
sys.argv.remove("--no_clash_crispresso1")
call_root = "CRISPResso2"
entry_points = {
"console_scripts": [call_root+' = CRISPResso2.CRISPRessoCORE:main',
call_root+'Batch = CRISPResso2.CRISPRessoBatchCORE:main',
call_root+'Pooled = CRISPResso2.CRISPRessoPooledCORE:main',
call_root+'WGS = CRISPResso2.CRISPRessoWGSCORE:main',
call_root+'Compare = CRISPResso2.CRISPRessoCompareCORE:main',
call_root+'PooledWGSCompare = CRISPResso2.CRISPRessoPooledWGSCompareCORE:main',
call_root+'Aggregate = CRISPResso2.CRISPRessoAggregateCORE:main',
]
}
setup(name="CRISPResso2",
version=version,
author='Edilytics, Inc.',
author_email='[email protected]',
url='http://github.com/pinellolab/CRISPResso2',
package_dir={'CRISPResso2' : 'CRISPResso2'},
include_package_data = True,
packages=['CRISPResso2', 'CRISPResso2.CRISPRessoReports'],
entry_points=entry_points,
description="Software pipeline for the analysis of genome editing outcomes from deep sequencing data",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: Science/Research',
'License :: Other/Proprietary License',
'Operating System :: POSIX',
'Topic :: Scientific/Engineering :: Bio-Informatics',
'Programming Language :: Python :: 3 :: Only',
'Programming Language :: Cython',
],
install_requires=[
'pandas', # '>=0.15,<=0.24',
'matplotlib', # '>=1.3.1,<=2.2.3',
'seaborn', # '>0.7.1,<0.10',
'jinja2',
'scipy',
'numpy',
],
cmdclass = command_classes,
ext_modules = ext_modules
)
if __name__ == '__main__':
main()