LoopStructural 1.0.3__zip → 1.0.71.dev0__zip
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/__init__.py +12 -7
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/datasets/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/datasets/__pycache__/_base.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__init__.py +3 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/base_structured_3d_support.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/discrete_fold_interpolator.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/discrete_interpolator.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/finite_difference_interpolator.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/geological_interpolator.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/operator.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/piecewiselinear_interpolator.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/structured_grid.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/structured_tetra.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/__pycache__/surfe_wrapper.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/base_structured_3d_support.py +101 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/cython/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/cython/dsi_helper.c +4137 -2716
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/cython/dsi_helper.cp36-win_amd64.pyd +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/discrete_fold_interpolator.py +56 -22
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/discrete_interpolator.py +61 -28
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/finite_difference_interpolator.py +71 -11
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/geological_interpolator.py +22 -3
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/operator.py +16 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/piecewiselinear_interpolator.py +150 -11
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/structured_grid.py +31 -69
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/structured_tetra.py +89 -45
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/interpolators/surfe_wrapper.py +7 -8
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/core/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/core/__pycache__/geological_model.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/core/__pycache__/geological_model_graph.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/core/__pycache__/stratigraphic_column.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/core/geological_model.py +515 -197
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/core/geological_model_graph.py +881 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/core/stratigraphic_column.py +5 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/__init__.py +1 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/__pycache__/fault_builder.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/__pycache__/fault_function.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/__pycache__/fault_function_feature.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/__pycache__/fault_segment.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/fault_builder.py +127 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/fault_function.py +2 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/fault_function_feature.py +2 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fault/fault_segment.py +30 -3
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__init__.py +1 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/cross_product_geological_feature.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/geological_feature.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/geological_feature_builder.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/lambda_geological_feature.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/region_feature.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/structural_frame.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/structural_frame_builder.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/__pycache__/unconformity_feature.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/cross_product_geological_feature.py +18 -5
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/geological_feature.py +22 -49
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/geological_feature_builder.py +171 -47
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/lambda_geological_feature.py +31 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/region_feature.py +3 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/structural_frame.py +28 -11
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/structural_frame_builder.py +32 -22
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/features/unconformity_feature.py +6 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/__pycache__/fold.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/__pycache__/fold_rotation_angle.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/__pycache__/fold_rotation_angle_feature.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/__pycache__/foldframe.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/__pycache__/svariogram.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/fold.py +13 -5
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/fold_rotation_angle.py +5 -4
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/fold_rotation_angle_feature.py +2 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/foldframe.py +7 -5
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/modelling/fold/svariogram.py +2 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__init__.py +5 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/bounding_box.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/exceptions.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/helper.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/logging.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/map2loop.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/regions.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/__pycache__/utils.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/bounding_box.py +21 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/exceptions.py +2 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/helper.py +10 -2
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/logging.py +60 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/map2loop.py +128 -37
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/regions.py +11 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/utils/utils.py +40 -47
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/__pycache__/map_viewer.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/__pycache__/model_plotter.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/__pycache__/model_visualisation.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/__pycache__/rotation_angle_plotter.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/__pycache__/sphinx_scraper.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/__pycache__/stratigraphic_column.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/map_viewer.py +236 -36
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/model_plotter.py +2 -1
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/model_visualisation.py +427 -79
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/rotation_angle_plotter.py +29 -12
- Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/stratigraphic_column.py +60 -0
- Miniconda/envs/loop/Lib/site-packages/{LoopStructural-1.0.3-py3.6.egg-info → LoopStructural-1.0.71.dev0-py3.6.egg-info}/PKG-INFO +1 -1
- Miniconda/envs/loop/Lib/site-packages/{LoopStructural-1.0.3-py3.6.egg-info → LoopStructural-1.0.71.dev0-py3.6.egg-info}/SOURCES.txt +10 -5
- Miniconda/envs/loop/Lib/site-packages/LoopStructural-1.0.71.dev0-py3.6.egg-info/requires.txt +8 -0
- Miniconda/envs/loop/Lib/site-packages/tests/__pycache__/__init__.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/LoopStructural-1.0.3-py3.6.egg-info/requires.txt +0 -3
- Miniconda/envs/loop/Lib/site-packages/tests/__pycache__/test_faults.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/tests/__pycache__/test_fold.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/tests/__pycache__/test_interpolator.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/tests/__pycache__/test_refolded.cpython-36.pyc +0 -0
- Miniconda/envs/loop/Lib/site-packages/tests/test_faults.py +0 -17
- Miniconda/envs/loop/Lib/site-packages/tests/test_fold.py +0 -57
- Miniconda/envs/loop/Lib/site-packages/tests/test_interpolator.py +0 -88
- Miniconda/envs/loop/Lib/site-packages/tests/test_refolded.py +0 -22
- /Miniconda/envs/loop/Lib/site-packages/{LoopStructural-1.0.3-py3.6.egg-info → LoopStructural-1.0.71.dev0-py3.6.egg-info}/dependency_links.txt +0 -0
- /Miniconda/envs/loop/Lib/site-packages/{LoopStructural-1.0.3-py3.6.egg-info → LoopStructural-1.0.71.dev0-py3.6.egg-info}/top_level.txt +0 -0
Miniconda/envs/loop/Lib/site-packages/LoopStructural/visualisation/rotation_angle_plotter.py
CHANGED
|
@@ -3,19 +3,21 @@ import logging
|
|
|
3
3
|
import matplotlib.pyplot as plt
|
|
4
4
|
import numpy as np
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
from LoopStructural.utils import getLogger
|
|
7
|
+
logger = getLogger(__name__)
|
|
7
8
|
|
|
8
9
|
|
|
9
10
|
class RotationAnglePlotter:
|
|
10
|
-
def __init__(self, feature):
|
|
11
|
+
def __init__(self, feature, axis=True):
|
|
11
12
|
"""
|
|
12
13
|
|
|
13
14
|
"""
|
|
14
|
-
self.fig, self.ax = plt.subplots(2, 2, figsize=(
|
|
15
|
+
self.fig, self.ax = plt.subplots(2, 2, figsize=(30, 15))
|
|
15
16
|
self.ax[0][0].set_ylim(-90, 90)
|
|
16
17
|
self.ax[1][0].set_ylim(-90, 90)
|
|
17
18
|
self.feature = feature
|
|
18
|
-
|
|
19
|
+
|
|
20
|
+
def plot(self, x, y, ix, iy, symb,**kwargs):
|
|
19
21
|
"""
|
|
20
22
|
|
|
21
23
|
Parameters
|
|
@@ -31,36 +33,51 @@ class RotationAnglePlotter:
|
|
|
31
33
|
-------
|
|
32
34
|
|
|
33
35
|
"""
|
|
34
|
-
self.ax[iy][ix].plot(x, y, symb)
|
|
35
|
-
|
|
36
|
+
return self.ax[iy][ix].plot(x, y, symb,**kwargs)
|
|
37
|
+
def default_titles(self):
|
|
38
|
+
self.ax[0][0].set_title('Fold Axis S-Plot')
|
|
39
|
+
self.ax[0][1].set_title('Fold Axis S-Variogram')
|
|
40
|
+
self.ax[1][0].set_title('Fold Limb S-Plot')
|
|
41
|
+
self.ax[1][1].set_title('Fold Limb S-Variogram')
|
|
42
|
+
|
|
43
|
+
self.ax[1][1].set_xlabel('Variogram Steps')
|
|
44
|
+
self.ax[1][1].set_ylabel('Fold Limb S-Variogram')
|
|
45
|
+
self.ax[1][0].set_ylabel('Fold Limb Rotation Angle')
|
|
46
|
+
self.ax[1][0].set_xlabel('Fold Frame Axial Surface Field')
|
|
47
|
+
|
|
48
|
+
self.ax[0][1].set_xlabel('Variogram Steps')
|
|
49
|
+
self.ax[0][1].set_ylabel('Fold Axis S-Variogram')
|
|
50
|
+
self.ax[0][0].set_ylabel('Fold Axis Rotation Angle')
|
|
51
|
+
self.ax[0][0].set_xlabel('Fold Frame Axis Direction Field')
|
|
36
52
|
def add_fold_limb_data(self, symb="bo",**kwargs):
|
|
37
53
|
fold_frame = self.feature.fold.fold_limb_rotation.fold_frame_coordinate
|
|
38
54
|
rotation = self.feature.fold.fold_limb_rotation.rotation_angle
|
|
39
|
-
self.plot(fold_frame, rotation, 0, 1, symb,**kwargs)
|
|
55
|
+
return self.plot(fold_frame, rotation, 0, 1, symb,**kwargs)
|
|
56
|
+
|
|
40
57
|
|
|
41
58
|
def add_fold_limb_curve(self, symb='r-',**kwargs):
|
|
42
59
|
x = np.linspace(self.feature.fold.foldframe[0].min(),self.feature.fold.foldframe[0].max(),100)
|
|
43
|
-
self.plot(x,self.feature.fold.fold_limb_rotation(x), 0, 1, symb,**kwargs)
|
|
60
|
+
return self.plot(x,self.feature.fold.fold_limb_rotation(x), 0, 1, symb,**kwargs)
|
|
44
61
|
|
|
45
62
|
def add_axis_svariogram(self, symb='bo',**kwargs):
|
|
46
63
|
svariogram = self.feature.fold.fold_axis_rotation.svario
|
|
47
64
|
if svariogram:
|
|
48
65
|
svariogram.calc_semivariogram()
|
|
49
|
-
self.plot(svariogram.lags, svariogram.variogram, 1,
|
|
66
|
+
return self.plot(svariogram.lags, svariogram.variogram, 1, 0, symb,**kwargs)
|
|
50
67
|
|
|
51
68
|
def add_limb_svariogram(self, symb='bo', **kwargs):
|
|
52
69
|
svariogram = self.feature.fold.fold_limb_rotation.svario
|
|
53
70
|
if svariogram:
|
|
54
71
|
svariogram.calc_semivariogram()
|
|
55
|
-
self.plot(svariogram.lags, svariogram.variogram, 1, 1, symb,**kwargs)
|
|
72
|
+
return self.plot(svariogram.lags, svariogram.variogram, 1, 1, symb,**kwargs)
|
|
56
73
|
|
|
57
74
|
def add_fold_axis_data(self, symb='bo',**kwargs):
|
|
58
75
|
fold_frame = self.feature.fold.fold_axis_rotation.fold_frame_coordinate
|
|
59
76
|
rotation = self.feature.fold.fold_axis_rotation.rotation_angle
|
|
60
|
-
self.plot(fold_frame, rotation, 0,
|
|
77
|
+
return self.plot(fold_frame, rotation, 0, 0, symb,**kwargs)
|
|
61
78
|
|
|
62
79
|
def add_fold_axis_curve(self, symb='r-',**kwargs):
|
|
63
80
|
x = np.linspace(self.feature.fold.foldframe[1].min(),self.feature.fold.foldframe[1].max(),100)
|
|
64
|
-
self.plot(x,self.feature.fold.fold_axis_rotation(x), 0,
|
|
81
|
+
return self.plot(x,self.feature.fold.fold_axis_rotation(x), 0, 0, symb,**kwargs)
|
|
65
82
|
|
|
66
83
|
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import numpy as np
|
|
2
|
+
import matplotlib.pyplot as plt
|
|
3
|
+
from matplotlib import cm
|
|
4
|
+
from matplotlib.patches import Polygon
|
|
5
|
+
from matplotlib.collections import PatchCollection
|
|
6
|
+
|
|
7
|
+
class StratigraphicColumnView:
|
|
8
|
+
def __init__(self,model,ax=None,cmap=None, labels = None):
|
|
9
|
+
n_units = 0 #count how many discrete colours
|
|
10
|
+
xmin = 0
|
|
11
|
+
ymin = 0
|
|
12
|
+
ymax = 1
|
|
13
|
+
xmax = 1
|
|
14
|
+
if ax is None:
|
|
15
|
+
fig, ax = plt.subplots(figsize=(2,10))
|
|
16
|
+
patches = []
|
|
17
|
+
for g in model.stratigraphic_column.keys():
|
|
18
|
+
if g == 'faults':
|
|
19
|
+
continue
|
|
20
|
+
for u in model.stratigraphic_column[g].keys():
|
|
21
|
+
n_units+=1
|
|
22
|
+
ymin = -model.stratigraphic_column[g][u]['min']
|
|
23
|
+
if np.isinf(model.stratigraphic_column[g][u]['min']):
|
|
24
|
+
ymin = 0
|
|
25
|
+
ymax = -model.stratigraphic_column[g][u]['max']
|
|
26
|
+
if np.isinf(ymax):
|
|
27
|
+
ymin = ymax + (ymax-ymin)*(1+np.random.rand())
|
|
28
|
+
polygon_points = np.array([[xmin,ymin],[xmax,ymin],[xmax,ymax],[xmin,ymax]])
|
|
29
|
+
patches.append(Polygon(polygon_points))
|
|
30
|
+
xy = (0,ymin+(ymax-ymin)/2)
|
|
31
|
+
if labels:
|
|
32
|
+
ax.annotate(labels[u],xy)
|
|
33
|
+
else:
|
|
34
|
+
ax.annotate(u,xy)
|
|
35
|
+
if cmap is None:
|
|
36
|
+
import matplotlib.colors as colors
|
|
37
|
+
colours = []
|
|
38
|
+
boundaries = []
|
|
39
|
+
data = []
|
|
40
|
+
for g in model.stratigraphic_column.keys():
|
|
41
|
+
if g == 'faults':
|
|
42
|
+
continue
|
|
43
|
+
for u, v in model.stratigraphic_column[g].items():
|
|
44
|
+
data.append((v['id'],v['colour']))
|
|
45
|
+
colours.append(v['colour'])
|
|
46
|
+
boundaries.append(v['id'])#print(u,v)
|
|
47
|
+
cmap = colors.ListedColormap(colours)
|
|
48
|
+
else:
|
|
49
|
+
cmap = cm.get_cmap(cmap,n_units-1)
|
|
50
|
+
ci = 0
|
|
51
|
+
p = PatchCollection(patches, cmap=cmap)
|
|
52
|
+
|
|
53
|
+
colors = np.arange(len(patches))
|
|
54
|
+
p.set_array(np.array(colors))
|
|
55
|
+
|
|
56
|
+
ax.add_collection(p)
|
|
57
|
+
|
|
58
|
+
ax.set_ylim(ymax+(ymax-ymin)*-2,0)#ax.set_ylim(0,ymax)
|
|
59
|
+
ax.axis('off')
|
|
60
|
+
|
|
@@ -10,6 +10,7 @@ LoopStructural/interpolators/cython/dsi_helper.c
|
|
|
10
10
|
LoopStructural/datasets/__init__.py
|
|
11
11
|
LoopStructural/datasets/_base.py
|
|
12
12
|
LoopStructural/interpolators/__init__.py
|
|
13
|
+
LoopStructural/interpolators/base_structured_3d_support.py
|
|
13
14
|
LoopStructural/interpolators/discrete_fold_interpolator.py
|
|
14
15
|
LoopStructural/interpolators/discrete_interpolator.py
|
|
15
16
|
LoopStructural/interpolators/finite_difference_interpolator.py
|
|
@@ -24,7 +25,10 @@ LoopStructural/interpolators/cython/dsi_helper.c
|
|
|
24
25
|
LoopStructural/modelling/__init__.py
|
|
25
26
|
LoopStructural/modelling/core/__init__.py
|
|
26
27
|
LoopStructural/modelling/core/geological_model.py
|
|
28
|
+
LoopStructural/modelling/core/geological_model_graph.py
|
|
29
|
+
LoopStructural/modelling/core/stratigraphic_column.py
|
|
27
30
|
LoopStructural/modelling/fault/__init__.py
|
|
31
|
+
LoopStructural/modelling/fault/fault_builder.py
|
|
28
32
|
LoopStructural/modelling/fault/fault_function.py
|
|
29
33
|
LoopStructural/modelling/fault/fault_function_feature.py
|
|
30
34
|
LoopStructural/modelling/fault/fault_segment.py
|
|
@@ -32,6 +36,7 @@ LoopStructural/modelling/features/__init__.py
|
|
|
32
36
|
LoopStructural/modelling/features/cross_product_geological_feature.py
|
|
33
37
|
LoopStructural/modelling/features/geological_feature.py
|
|
34
38
|
LoopStructural/modelling/features/geological_feature_builder.py
|
|
39
|
+
LoopStructural/modelling/features/lambda_geological_feature.py
|
|
35
40
|
LoopStructural/modelling/features/region_feature.py
|
|
36
41
|
LoopStructural/modelling/features/structural_frame.py
|
|
37
42
|
LoopStructural/modelling/features/structural_frame_builder.py
|
|
@@ -43,9 +48,12 @@ LoopStructural/modelling/fold/fold_rotation_angle_feature.py
|
|
|
43
48
|
LoopStructural/modelling/fold/foldframe.py
|
|
44
49
|
LoopStructural/modelling/fold/svariogram.py
|
|
45
50
|
LoopStructural/utils/__init__.py
|
|
51
|
+
LoopStructural/utils/bounding_box.py
|
|
46
52
|
LoopStructural/utils/exceptions.py
|
|
47
53
|
LoopStructural/utils/helper.py
|
|
54
|
+
LoopStructural/utils/logging.py
|
|
48
55
|
LoopStructural/utils/map2loop.py
|
|
56
|
+
LoopStructural/utils/regions.py
|
|
49
57
|
LoopStructural/utils/utils.py
|
|
50
58
|
LoopStructural/visualisation/__init__.py
|
|
51
59
|
LoopStructural/visualisation/map_viewer.py
|
|
@@ -53,8 +61,5 @@ LoopStructural/visualisation/model_plotter.py
|
|
|
53
61
|
LoopStructural/visualisation/model_visualisation.py
|
|
54
62
|
LoopStructural/visualisation/rotation_angle_plotter.py
|
|
55
63
|
LoopStructural/visualisation/sphinx_scraper.py
|
|
56
|
-
|
|
57
|
-
tests/
|
|
58
|
-
tests/test_fold.py
|
|
59
|
-
tests/test_interpolator.py
|
|
60
|
-
tests/test_refolded.py
|
|
64
|
+
LoopStructural/visualisation/stratigraphic_column.py
|
|
65
|
+
tests/__init__.py
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
from LoopStructural import GeologicalModel
|
|
2
|
-
from LoopStructural.datasets import load_intrusion
|
|
3
|
-
data, bb = load_intrusion()
|
|
4
|
-
model = GeologicalModel(bb[0,:],bb[1,:])
|
|
5
|
-
model.set_model_data(data)
|
|
6
|
-
fault = model.create_and_add_fault('fault',
|
|
7
|
-
500,
|
|
8
|
-
nelements=2000,
|
|
9
|
-
steps=4,
|
|
10
|
-
interpolatortype='PLI',
|
|
11
|
-
buffer=0.2)
|
|
12
|
-
strati = model.create_and_add_foliation('strati',
|
|
13
|
-
nelements=30000,
|
|
14
|
-
interpolatortype='PLI',
|
|
15
|
-
cgw=0.1,
|
|
16
|
-
buffer=0.1
|
|
17
|
-
)
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
from LoopStructural import GeologicalModel
|
|
2
|
-
from LoopStructural.datasets import load_noddy_single_fold
|
|
3
|
-
|
|
4
|
-
import pandas as pd
|
|
5
|
-
|
|
6
|
-
data, boundary_points = load_noddy_single_fold()
|
|
7
|
-
data.head()
|
|
8
|
-
def test_average_fold_axis():
|
|
9
|
-
mdata = pd.concat([data[:100],data[data['feature_name']=='s1']])
|
|
10
|
-
model = GeologicalModel(boundary_points[0,:],boundary_points[1,:])
|
|
11
|
-
model.set_model_data(mdata)
|
|
12
|
-
fold_frame = model.create_and_add_fold_frame('s1',nelements=10000)
|
|
13
|
-
stratigraphy = model.create_and_add_folded_foliation('s0',
|
|
14
|
-
fold_frame,
|
|
15
|
-
nelements=10000,
|
|
16
|
-
av_fold_axis=True
|
|
17
|
-
# fold_axis=[-6.51626577e-06, -5.00013645e-01, -8.66017526e-01],
|
|
18
|
-
# limb_wl=1
|
|
19
|
-
)
|
|
20
|
-
def test_fixed_fold_axis():
|
|
21
|
-
mdata = pd.concat([data[:100],data[data['feature_name']=='s1']])
|
|
22
|
-
model = GeologicalModel(boundary_points[0,:],boundary_points[1,:])
|
|
23
|
-
model.set_model_data(mdata)
|
|
24
|
-
fold_frame = model.create_and_add_fold_frame('s1',nelements=10000)
|
|
25
|
-
stratigraphy = model.create_and_add_folded_foliation('s0',
|
|
26
|
-
fold_frame,
|
|
27
|
-
nelements=10000,
|
|
28
|
-
# av_fold_axis=True
|
|
29
|
-
fold_axis=[-6.51626577e-06, -5.00013645e-01, -8.66017526e-01],
|
|
30
|
-
# limb_wl=1
|
|
31
|
-
)
|
|
32
|
-
|
|
33
|
-
def test_fixed_wavelength():
|
|
34
|
-
mdata = pd.concat([data[:100],data[data['feature_name']=='s1']])
|
|
35
|
-
model = GeologicalModel(boundary_points[0,:],boundary_points[1,:])
|
|
36
|
-
model.set_model_data(mdata)
|
|
37
|
-
fold_frame = model.create_and_add_fold_frame('s1',nelements=10000)
|
|
38
|
-
stratigraphy = model.create_and_add_folded_foliation('s0',
|
|
39
|
-
fold_frame,
|
|
40
|
-
nelements=10000,
|
|
41
|
-
# av_fold_axis=True
|
|
42
|
-
fold_axis=[-6.51626577e-06, -5.00013645e-01, -8.66017526e-01],
|
|
43
|
-
limb_wl=1
|
|
44
|
-
)
|
|
45
|
-
|
|
46
|
-
def test_no_fold_frame():
|
|
47
|
-
mdata = pd.concat([data[:100],data[data['feature_name']=='s1']])
|
|
48
|
-
model = GeologicalModel(boundary_points[0,:],boundary_points[1,:])
|
|
49
|
-
model.set_model_data(mdata)
|
|
50
|
-
fold_frame = model.create_and_add_fold_frame('s1',nelements=10000)
|
|
51
|
-
stratigraphy = model.create_and_add_folded_foliation('s0',
|
|
52
|
-
# fold_frame,
|
|
53
|
-
nelements=10000,
|
|
54
|
-
# av_fold_axis=True
|
|
55
|
-
fold_axis=[-6.51626577e-06, -5.00013645e-01, -8.66017526e-01],
|
|
56
|
-
limb_wl=1
|
|
57
|
-
)
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
from LoopStructural import GeologicalModel
|
|
2
|
-
from LoopStructural.datasets import load_claudius
|
|
3
|
-
|
|
4
|
-
def test_create_model():
|
|
5
|
-
data, bb = load_claudius()
|
|
6
|
-
model = GeologicalModel(bb[0,:],bb[1,:])
|
|
7
|
-
|
|
8
|
-
def test_add_data():
|
|
9
|
-
data, bb = load_claudius()
|
|
10
|
-
model = GeologicalModel(bb[0,:],bb[1,:])
|
|
11
|
-
model.set_model_data(data)
|
|
12
|
-
|
|
13
|
-
def test_create_stratigraphy_FDI_cg():
|
|
14
|
-
data, bb = load_claudius()
|
|
15
|
-
model = GeologicalModel(bb[0, :], bb[1, :])
|
|
16
|
-
model.set_model_data(data)
|
|
17
|
-
s0 = model.create_and_add_foliation('s0',
|
|
18
|
-
interpolatortype='FDI',
|
|
19
|
-
nelements=1000,
|
|
20
|
-
solver='cg',
|
|
21
|
-
damp=False)
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
def test_remove_constraints_PLI():
|
|
25
|
-
data, bb = load_claudius()
|
|
26
|
-
model = GeologicalModel(bb[0, :], bb[1, :])
|
|
27
|
-
model.set_model_data(data)
|
|
28
|
-
s0 = model.create_and_add_foliation('s0',
|
|
29
|
-
interpolatortype='FDI',
|
|
30
|
-
nelements=1000,
|
|
31
|
-
solver='cg',
|
|
32
|
-
damp=False)
|
|
33
|
-
|
|
34
|
-
def test_create_stratigraphy_FDI_lu():
|
|
35
|
-
data, bb = load_claudius()
|
|
36
|
-
model = GeologicalModel(bb[0, :], bb[1, :])
|
|
37
|
-
model.set_model_data(data)
|
|
38
|
-
s0 = model.create_and_add_foliation('s0',
|
|
39
|
-
interpolatortype='FDI',
|
|
40
|
-
nelements=1000,
|
|
41
|
-
solver='lu',
|
|
42
|
-
damp=True)
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
def test_create_stratigraphy_FDI_pyamg():
|
|
46
|
-
data, bb = load_claudius()
|
|
47
|
-
model = GeologicalModel(bb[0, :], bb[1, :])
|
|
48
|
-
model.set_model_data(data)
|
|
49
|
-
s0 = model.create_and_add_foliation('s0',
|
|
50
|
-
interpolatortype='FDI',
|
|
51
|
-
nelements=1000,
|
|
52
|
-
solver='pyamg',
|
|
53
|
-
damp=True)
|
|
54
|
-
|
|
55
|
-
def test_create_stratigraphy_PLI_cg():
|
|
56
|
-
data, bb = load_claudius()
|
|
57
|
-
model = GeologicalModel(bb[0, :], bb[1, :])
|
|
58
|
-
model.set_model_data(data)
|
|
59
|
-
s0 = model.create_and_add_foliation('s0',
|
|
60
|
-
interpolatortype='PLI',
|
|
61
|
-
nelements=1000,
|
|
62
|
-
solver='cg',
|
|
63
|
-
damp=False)
|
|
64
|
-
|
|
65
|
-
def test_create_stratigraphy_PLI_lu():
|
|
66
|
-
data, bb = load_claudius()
|
|
67
|
-
model = GeologicalModel(bb[0, :], bb[1, :])
|
|
68
|
-
model.set_model_data(data)
|
|
69
|
-
s0 = model.create_and_add_foliation('s0',
|
|
70
|
-
interpolatortype='PLI',
|
|
71
|
-
nelements=1000,
|
|
72
|
-
solver='lu',
|
|
73
|
-
damp=True)
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
def test_create_stratigraphy_PLI_pyamg():
|
|
77
|
-
data, bb = load_claudius()
|
|
78
|
-
model = GeologicalModel(bb[0, :], bb[1, :])
|
|
79
|
-
model.set_model_data(data)
|
|
80
|
-
s0 = model.create_and_add_foliation('s0',
|
|
81
|
-
interpolatortype='PLI',
|
|
82
|
-
nelements=1000,
|
|
83
|
-
solver='pyamg',
|
|
84
|
-
damp=True)
|
|
85
|
-
|
|
86
|
-
def test_model_with_data_outside_of_bounding_box():
|
|
87
|
-
pass
|
|
88
|
-
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
from LoopStructural import GeologicalModel
|
|
2
|
-
from LoopStructural.datasets import load_laurent2016
|
|
3
|
-
|
|
4
|
-
def average_axis():
|
|
5
|
-
data, bb = load_laurent2016()
|
|
6
|
-
|
|
7
|
-
model = GeologicalModel(bb[0,:],bb[1,:])
|
|
8
|
-
model.set_model_data(data)
|
|
9
|
-
s2 = model.create_and_add_fold_frame('s2',
|
|
10
|
-
nelements=10000)
|
|
11
|
-
|
|
12
|
-
s1 = model.create_and_add_folded_fold_frame('s1',
|
|
13
|
-
limb_wl=.4,
|
|
14
|
-
av_fold_axis=True,
|
|
15
|
-
nelements=50000
|
|
16
|
-
)
|
|
17
|
-
|
|
18
|
-
s0 = model.create_and_add_folded_fold_frame('s0',
|
|
19
|
-
limb_wl=1.,
|
|
20
|
-
av_fold_axis=True,
|
|
21
|
-
nelements=50000
|
|
22
|
-
)
|
|
File without changes
|