-
Notifications
You must be signed in to change notification settings - Fork 16
/
setup.py
117 lines (103 loc) · 3.14 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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
# -*- coding: utf-8 -*-
import os
from setuptools import setup, find_packages
# load __version__ without importing anything
version_file = os.path.join(
os.path.dirname(__file__),
'pyslm/version.py')
with open(version_file, 'r') as f:
# use eval to get a clean string of version from file
__version__ = eval(f.read().strip().split('=')[-1])
# minimal requirements for installing PySLM
# note that `pip` requires setuptools itself
requirements_default = set([
'numpy', # all data structures
'scipy',
'scikit-image',
'setuptools', # used for packaging
'shapely',
'cython',
'pyclipr',
'manifold3d',
'Rtree',
'networkx',
'matplotlib',
'trimesh'
])
# "easy" requirements should install without compiling
# anything on Windows, Linux, and Mac, for Python 2.7-3.4+
requirements_easy = set([
'setuptools', # do setuptools stuff
'shapely',
'Rtree',
'scikit-image',
'networkx',
'trimesh', # Required for meshing geometry
'triangle',
'colorlog']) # log in pretty colors
requirements_supports = set([
'setuptools', # do setuptools stuff
'shapely',
'Rtree',
'scikit-image',
'networkx',
'trimesh', # Required for meshing geometry
'triangle',
'vispy',
'PyQt5',
'mapbox-earcut'
'colorlog']) # log in pretty colors
# requirements for building documentation
# Note API is only read from pyclipper in external project
requirements_docs = set([
'sphinx',
'jupyter',
'sphinx_rtd_theme',
'sphinx-paramlinks'
'pypandoc',
'pyclipr'
'autodocsumm',
'numpy',
'shapely',
'scipy',
'scikit-image'
'pyclipper',
'networkx',
'trimesh',
'cython'])
with open('README.rst') as f:
readme = f.read()
with open('LICENSE') as f:
license = f.read()
setup(
name='PythonSLM',
version=__version__,
description='Python Package for Additive Manufacturing and 3D Printing Development',
long_description=readme,
long_description_content_type='text/x-rst',
author='Luke Parry',
author_email='dev@lukeparry.uk',
url='https://github.com/drlukeparry/pyslm',
keywords=['3D Printing', 'AM', 'Additive Manufacturing', 'Geometry', 'SLM', 'Selective Laser Melting', 'L-PBF'],
python_requires='>=3.7',
classifiers=[
'Programming Language :: Python',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11'
'Natural Language :: English',
'Topic :: Scientific/Engineering'],
license="",
packages=find_packages(exclude=('tests', 'docs', 'examples')),
install_requires=list(requirements_default),
extras_require={'easy': list(requirements_easy),
'support': list(requirements_supports),
'docs': list(requirements_docs)},
project_urls = {
'Documentation': 'https://pyslm.readthedocs.io/en/latest/',
'Source': 'https://github.com/drylukeparry/pyslm/pyslm/',
'Tracker': 'https://github.com/drlukeparry/pyslm/issues'
}
)