Repository navigation
Expand file tree
/
Copy pathsetup.py
More file actions
144 lines (132 loc) · 3.91 KB
/
Copy pathsetup.py
File metadata and controls
144 lines (132 loc) · 3.91 KB
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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
LASIF (LArge-scale Seismic Inversion Framework)
Data management for seismological full seismic waveform inversions using the
Salvus suite of tools.
:copyright:
Lion Krischer (krischer@geophysik.uni-muenchen.de),
Solvi Thrastarson (soelvi.thrastarson@erdw.ethz.ch),
Dirk-Philip van Herwaarden (dirkphilip.vanherwaarden@erdw.ethz.ch),
Andreas Fichtner (A.Fichtner@uu.nl) 2012-2020
:license:
GNU General Public License, Version 3
(http://www.gnu.org/copyleft/gpl.html)
"""
import inspect
import os
import sys
from setuptools import setup, find_packages
# Be very visible with the requires Python version!
# _v = sys.version_info
# if (_v.major, _v.minor) != (3, 7):
# print("\n\n============================================")
# print("============================================")
# print(" LASIF 2 requires Python 3.7! ")
# print("============================================")
# print("============================================\n\n")
# raise Exception("LASIF 2 requires Python 3.7")
# Import the version string.
path = os.path.join(
os.path.abspath(os.path.dirname(inspect.getfile(inspect.currentframe()))),
"lasif",
)
sys.path.insert(0, path)
from version import get_git_version # noqa
def get_package_data():
"""
Returns a list of all files needed for the installation relativ to the
"lasif" subfolder.
"""
filenames = []
# The lasif root dir.
root_dir = os.path.join(
os.path.dirname(
os.path.abspath(inspect.getfile(inspect.currentframe()))
),
"lasif",
)
# Recursively include all files in these folders:
folders = [
os.path.join(root_dir, "tests", "baseline_images"),
os.path.join(root_dir, "tests", "data"),
]
for folder in folders:
for directory, _, files in os.walk(folder):
for filename in files:
# Exclude hidden files.
if filename.startswith("."):
continue
filenames.append(
os.path.relpath(
os.path.join(directory, filename), root_dir
)
)
return filenames
setup_config = dict(
name="lasif",
version="0.0.1",
description="",
author="Lion Krischer, Dirk-Philip van Herwaarden and Solvi Thrastarson",
author_email="soelvi.thrastarson@erdw.ethz.ch",
url="https://github.com/dirkphilip/LASIF_2.0",
packages=find_packages(),
python_requires="~=3.7",
license="GNU General Public License, version 3 (GPLv3)",
platforms="OS Independent",
classifiers=[
"Environment :: Console",
"Intended Audience :: Science/Research",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3.7",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Physics",
],
install_requires=[
"scipy",
"cmasher",
"cartopy>=0.20.2",
"obspy",
"pyasdf",
"progressbar",
"colorama",
"joblib",
"pytest",
"nose",
"mock",
"pip",
"sphinx",
"sphinx_rtd_theme",
"seaborn",
"numexpr",
"ipython",
"dill",
"prov",
"pandas",
"h5py",
"pyqtgraph",
"ipykernel",
"pathlib",
"ipywidgets",
"pyasdf",
"pythreejs",
"geographiclib",
"flask-cache",
"geojson"],
extras_require={
"dev": [
"black",
],
},
package_data={
"lasif": get_package_data()},
entry_points={
"console_scripts": [
"lasif = lasif.scripts.lasif_cli:main",
"iris2quakeml = lasif.scripts.iris2quakeml:main",
]
},
)
if __name__ == "__main__":
setup(**setup_config)