LoopStructural 1.0.9__cp36-cp36m-win32.whl

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.
Files changed (77) hide show
  1. LoopStructural/__init__.py +36 -0
  2. LoopStructural/analysis/__init__.py +2 -0
  3. LoopStructural/analysis/_fault_displacement.py +67 -0
  4. LoopStructural/analysis/_fault_intersection.py +36 -0
  5. LoopStructural/analysis/_plane_fit.py +43 -0
  6. LoopStructural/datasets/__init__.py +12 -0
  7. LoopStructural/datasets/_base.py +65 -0
  8. LoopStructural/datasets/data/claudius.csv +21049 -0
  9. LoopStructural/datasets/data/claudiusbb.txt +2 -0
  10. LoopStructural/datasets/data/duplex.csv +126 -0
  11. LoopStructural/datasets/data/duplexbb.txt +2 -0
  12. LoopStructural/datasets/data/intrusion.csv +1017 -0
  13. LoopStructural/datasets/data/intrusionbb.txt +2 -0
  14. LoopStructural/datasets/data/onefoldbb.txt +2 -0
  15. LoopStructural/datasets/data/onefolddata.csv +2226 -0
  16. LoopStructural/datasets/data/refolded_bb.txt +2 -0
  17. LoopStructural/datasets/data/refolded_fold.csv +2126 -0
  18. LoopStructural/interpolators/__init__.py +34 -0
  19. LoopStructural/interpolators/base_structured_3d_support.py +101 -0
  20. LoopStructural/interpolators/cython/__init__.py +0 -0
  21. LoopStructural/interpolators/cython/dsi_helper.c +31046 -0
  22. LoopStructural/interpolators/cython/dsi_helper.cp36-win32.pyd +0 -0
  23. LoopStructural/interpolators/discrete_fold_interpolator.py +202 -0
  24. LoopStructural/interpolators/discrete_interpolator.py +584 -0
  25. LoopStructural/interpolators/finite_difference_interpolator.py +399 -0
  26. LoopStructural/interpolators/geological_interpolator.py +197 -0
  27. LoopStructural/interpolators/operator.py +61 -0
  28. LoopStructural/interpolators/piecewiselinear_interpolator.py +437 -0
  29. LoopStructural/interpolators/structured_grid.py +421 -0
  30. LoopStructural/interpolators/structured_tetra.py +681 -0
  31. LoopStructural/interpolators/surfe_wrapper.py +118 -0
  32. LoopStructural/modelling/__init__.py +46 -0
  33. LoopStructural/modelling/core/__init__.py +0 -0
  34. LoopStructural/modelling/core/geological_model.py +1513 -0
  35. LoopStructural/modelling/core/geological_model_graph.py +880 -0
  36. LoopStructural/modelling/core/stratigraphic_column.py +5 -0
  37. LoopStructural/modelling/fault/__init__.py +4 -0
  38. LoopStructural/modelling/fault/fault_builder.py +143 -0
  39. LoopStructural/modelling/fault/fault_function.py +188 -0
  40. LoopStructural/modelling/fault/fault_function_feature.py +76 -0
  41. LoopStructural/modelling/fault/fault_segment.py +298 -0
  42. LoopStructural/modelling/features/__init__.py +8 -0
  43. LoopStructural/modelling/features/cross_product_geological_feature.py +90 -0
  44. LoopStructural/modelling/features/geological_feature.py +252 -0
  45. LoopStructural/modelling/features/geological_feature_builder.py +414 -0
  46. LoopStructural/modelling/features/lambda_geological_feature.py +36 -0
  47. LoopStructural/modelling/features/region_feature.py +34 -0
  48. LoopStructural/modelling/features/structural_frame.py +133 -0
  49. LoopStructural/modelling/features/structural_frame_builder.py +206 -0
  50. LoopStructural/modelling/features/unconformity_feature.py +74 -0
  51. LoopStructural/modelling/fold/__init__.py +8 -0
  52. LoopStructural/modelling/fold/fold.py +143 -0
  53. LoopStructural/modelling/fold/fold_rotation_angle.py +133 -0
  54. LoopStructural/modelling/fold/fold_rotation_angle_feature.py +58 -0
  55. LoopStructural/modelling/fold/foldframe.py +193 -0
  56. LoopStructural/modelling/fold/svariogram.py +180 -0
  57. LoopStructural/utils/__init__.py +18 -0
  58. LoopStructural/utils/bounding_box.py +21 -0
  59. LoopStructural/utils/exceptions.py +10 -0
  60. LoopStructural/utils/helper.py +382 -0
  61. LoopStructural/utils/logging.py +60 -0
  62. LoopStructural/utils/map2loop.py +353 -0
  63. LoopStructural/utils/regions.py +11 -0
  64. LoopStructural/utils/utils.py +69 -0
  65. LoopStructural/visualisation/__init__.py +31 -0
  66. LoopStructural/visualisation/map_viewer.py +322 -0
  67. LoopStructural/visualisation/model_plotter.py +17 -0
  68. LoopStructural/visualisation/model_visualisation.py +1113 -0
  69. LoopStructural/visualisation/rotation_angle_plotter.py +83 -0
  70. LoopStructural/visualisation/sphinx_scraper.py +34 -0
  71. LoopStructural/visualisation/stratigraphic_column.py +60 -0
  72. LoopStructural-1.0.9.dist-info/LICENSE +21 -0
  73. LoopStructural-1.0.9.dist-info/METADATA +19 -0
  74. LoopStructural-1.0.9.dist-info/RECORD +77 -0
  75. LoopStructural-1.0.9.dist-info/WHEEL +5 -0
  76. LoopStructural-1.0.9.dist-info/top_level.txt +2 -0
  77. tests/__init__.py +0 -0
@@ -0,0 +1,34 @@
1
+ """
2
+ Interpolators and interpolation supports
3
+
4
+ Interpolation Submodules
5
+ ========================
6
+ .. autosummary::
7
+ :toctree: _autosummary
8
+
9
+ geological_interpolator
10
+ discrete_interpolator
11
+ piecewiselinear_interpolator
12
+ discrete_fold_interpolator
13
+ finite_difference_interpolator
14
+ surfe_wrapper
15
+
16
+ Interpolation Support Submodules
17
+ ================================
18
+
19
+ .. autosummary::
20
+ :toctree: _autosummary
21
+
22
+ structured_tetra
23
+ structured_grid
24
+ operator
25
+
26
+ """
27
+ from LoopStructural.interpolators.discrete_fold_interpolator import DiscreteFoldInterpolator
28
+ from LoopStructural.interpolators.finite_difference_interpolator import \
29
+ FiniteDifferenceInterpolator
30
+ from LoopStructural.interpolators.piecewiselinear_interpolator import \
31
+ PiecewiseLinearInterpolator
32
+ from LoopStructural.interpolators.structured_tetra import TetMesh
33
+ from LoopStructural.interpolators.structured_grid import StructuredGrid
34
+
@@ -0,0 +1,101 @@
1
+ import numpy as np
2
+ class BaseStructuredSupport:
3
+ """
4
+
5
+ """
6
+ def __init__(self,
7
+ origin=np.zeros(3),
8
+ nsteps=np.array([10, 10, 10]),
9
+ step_vector=np.ones(3),
10
+ ):
11
+ """
12
+
13
+ Parameters
14
+ ----------
15
+ origin - 3d list or numpy array
16
+ nsteps - 3d list or numpy array of ints
17
+ step_vector - 3d list or numpy array of int
18
+ """
19
+ # the geometry in the mesh can be calculated from the
20
+ # nsteps, step vector and origin
21
+ # we use property decorators to update these when different parts of
22
+ # the geometry need to change
23
+ # inisialise the private attributes
24
+ self._nsteps = nsteps
25
+ self._step_vector = step_vector
26
+ self._origin = np.array(origin)
27
+ self.supporttype='Base'
28
+
29
+ @property
30
+ def nsteps(self):
31
+ return self._nsteps
32
+ @nsteps.setter
33
+ def nsteps(self,nsteps):
34
+ #if nsteps changes we need to change the step vector
35
+ change_factor = nsteps/self.nsteps
36
+ self._step_vector/=change_factor
37
+ self._nsteps = nsteps
38
+
39
+
40
+ @property
41
+ def step_vector(self):
42
+ return self._step_vector
43
+
44
+ @step_vector.setter
45
+ def step_vector(self,step_vector):
46
+ change_factor = step_vector/self.step_vector
47
+ newsteps = self._nsteps/change_factor
48
+ self._nsteps =np.ceil(newsteps).astype(int)
49
+ self._step_vector = step_vector
50
+
51
+ @property
52
+ def origin(self):
53
+ return self._origin
54
+ @origin.setter
55
+ def origin(self,origin):
56
+ origin = np.array(origin)
57
+ length = self.maximum-origin
58
+ length /= self.step_vector
59
+ self._nsteps = np.ceil(length).astype(int)
60
+ self._origin = origin
61
+ @property
62
+ def maximum(self):
63
+ return self.origin+self.nsteps*self.step_vector
64
+ @maximum.setter
65
+ def maximum(self,maximum):
66
+ """
67
+ update the number of steps to fit new boundary
68
+ """
69
+ maximum = np.array(maximum,dtype=float)
70
+ length = maximum-self.origin
71
+ length /= self.step_vector
72
+ self._nsteps = np.ceil(length).astype(int)
73
+ @property
74
+ def n_nodes(self):
75
+ return np.product(self.nsteps)
76
+
77
+ @property
78
+ def nsteps_cells(self):
79
+ return self.nsteps -1
80
+ @property
81
+ def n_elements(self):
82
+ return np.product(self.nsteps_cells)
83
+ def __str__(self):
84
+ return 'LoopStructural interpolation support: {} \n'\
85
+ 'Origin: {} {} {} \n'\
86
+ 'Maximum: {} {} {} \n'\
87
+ 'Step Vector: {} {} {} \n'\
88
+ 'Number of Steps: {} {} {} \n'\
89
+ 'Degrees of freedon {}'.format(self.supporttype,self.origin[0],self.origin[1],self.origin[2],\
90
+ self.maximum[0],self.maximum[1],self.maximum[2],\
91
+ self.step_vector[0],self.step_vector[1],self.step_vector[2],\
92
+ self.nsteps[0],self.nsteps[1],self.nsteps[2],self.n_nodes)
93
+ @property
94
+ def nodes(self):
95
+ max = self.origin + self.nsteps_cells * self.step_vector
96
+ x = np.linspace(self.origin[0], max[0], self.nsteps[0])
97
+ y = np.linspace(self.origin[1], max[1], self.nsteps[1])
98
+ z = np.linspace(self.origin[2], max[2], self.nsteps[2])
99
+ xx, yy, zz = np.meshgrid(x, y, z, indexing='ij')
100
+ return np.array([xx.flatten(order='F'), yy.flatten(order='F'),
101
+ zz.flatten(order='F')]).T
File without changes