-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
51 lines (46 loc) · 2.06 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
from glob import glob
from setuptools import setup, find_packages, Extension
from distutils.command.build import build
# -------------------------------------------
class CustomBuild(build):
sub_commands = [('build_ext', build.has_ext_modules),
('build_py', build.has_pure_modules),
('build_clib', build.has_c_libraries),
('build_scripts', build.has_scripts)]
# noinspection PyTypeChecker
setup(name='xrdpattern',
version='0.9.2',
description='Python library for XrdPatterns including file import, file export and postprocessing functionalities',
install_requires=[
'numpy < 2.0.0',
'scipy',
'matplotlib',
'pymatgen',
'torch',
'gemmi',
'holytools',
'pandas',
'openpyxl',
'tensordict'
], long_description=("Python library for XrdPatterns including import from data files, "
"export as json file and postprocessing functionalities. The data file "
"import functionalities are built on C++ library xylib so beyond a standard "
"python install, this library also requires: "
"\n- A C++ compiler and standard library "
"\n- A C++ to python bridge (Swig)"),
packages=find_packages(),
author = 'Daniel Hollarek',
author_email = 'daniel.hollarek@googlemail.com',
license='LGPL2.1',
url='https://github.com/aimat-lab/xrdpattern',
ext_modules=[Extension('_xylib',
sources=glob('xylib/*.cpp') + ['xylib.i'],
language='c++',
swig_opts=['-c++', '-py3'],
include_dirs=['.'],
libraries=[])],
py_modules=['xylib'],
cmdclass={'build': CustomBuild},
package_data = {'xrdpattern.crystal.atomic_constants': ['*'],'xrdpattern.crystal.cifs': ['*'],
'xrdpattern.examples': ['*', 'datafolder/*']}
)