forked from pybamm-team/PyBaMM
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
63 lines (57 loc) · 1.92 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
try:
from setuptools import setup, find_packages
except ImportError:
from distutils.core import setup, find_packages
# Load text for description and license
with open("README.md") as f:
readme = f.read()
# Read version number from file
def load_version():
try:
import os
root = os.path.abspath(os.path.dirname(__file__))
with open(os.path.join(root, "pybamm", "version"), "r") as f:
version = f.read().strip().split(",")
return ".".join([str(int(x)) for x in version])
except Exception as e:
raise RuntimeError("Unable to read version number (" + str(e) + ").")
setup(
name="pybamm",
version=load_version(),
description="Python Battery Mathematical Modelling.",
long_description=readme,
url="https://github.com/pybamm-team/PyBaMM",
# include_package_data=True,
packages=find_packages(include=("pybamm", "pybamm.*")),
package_data={
"pybamm": [
"../input/parameters/lithium-ion/*.csv",
"../input/parameters/lithium-ion/*.py",
"../input/parameters/lead-acid/*.csv",
"../input/parameters/lead-acid/*.py",
]
},
# List of dependencies
install_requires=[
"numpy>=1.16",
"scipy>=1.0",
"pandas>=0.23",
"anytree>=2.4.3",
"autograd>=1.2",
"scikit-fem>=0.2.0",
"casadi>=3.5.0",
# Note: Matplotlib is loaded for debug plots, but to ensure pybamm runs
# on systems without an attached display, it should never be imported
# outside of plot() methods.
# Should not be imported
"matplotlib>=2.0",
],
extras_require={
"docs": ["sphinx>=1.5", "guzzle-sphinx-theme"], # For doc generation
"dev": [
"flake8>=3", # For code style checking
"black", # For code style auto-formatting
"jupyter", # For documentation and testing
],
},
)