py-pilecore 0.4.2__py3-none-any.whl → 0.5.0__py3-none-any.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.
Potentially problematic release.
This version of py-pilecore might be problematic. Click here for more details.
- {py_pilecore-0.4.2.dist-info → py_pilecore-0.5.0.dist-info}/METADATA +2 -2
- py_pilecore-0.5.0.dist-info/RECORD +33 -0
- {py_pilecore-0.4.2.dist-info → py_pilecore-0.5.0.dist-info}/WHEEL +1 -1
- pypilecore/__init__.py +2 -0
- pypilecore/_version.py +1 -1
- pypilecore/api.py +26 -6
- pypilecore/common/__init__.py +0 -0
- pypilecore/common/piles/__init__.py +6 -0
- pypilecore/common/piles/geometry/__init__.py +18 -0
- pypilecore/common/piles/geometry/components/__init__.py +10 -0
- pypilecore/common/piles/geometry/components/common.py +493 -0
- pypilecore/common/piles/geometry/components/rectangle.py +521 -0
- pypilecore/common/piles/geometry/components/round.py +435 -0
- pypilecore/common/piles/geometry/main.py +335 -0
- pypilecore/common/piles/geometry/materials.py +173 -0
- pypilecore/common/piles/main.py +290 -0
- pypilecore/common/piles/type.py +196 -0
- pypilecore/input/__init__.py +0 -2
- pypilecore/input/multi_cpt.py +7 -119
- pypilecore/input/soil_properties.py +12 -1
- pypilecore/results/grouper_result.py +3 -2
- pypilecore/results/multi_cpt_results.py +11 -8
- py_pilecore-0.4.2.dist-info/RECORD +0 -24
- pypilecore/input/pile_properties.py +0 -213
- pypilecore/results/pile_properties.py +0 -891
- {py_pilecore-0.4.2.dist-info → py_pilecore-0.5.0.dist-info}/LICENSE +0 -0
- {py_pilecore-0.4.2.dist-info → py_pilecore-0.5.0.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,290 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import Dict, List
|
|
4
|
+
|
|
5
|
+
from pypilecore.common.piles.geometry import PileGeometry
|
|
6
|
+
from pypilecore.common.piles.geometry.components import (
|
|
7
|
+
PrimaryPileComponentDimension,
|
|
8
|
+
RectPileGeometryComponent,
|
|
9
|
+
RoundPileGeometryComponent,
|
|
10
|
+
)
|
|
11
|
+
from pypilecore.common.piles.geometry.materials import MATERIALS, PileMaterial
|
|
12
|
+
from pypilecore.common.piles.type import PileType
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class PileProperties:
|
|
16
|
+
"""The PileProperties class represents all properties of a pile."""
|
|
17
|
+
|
|
18
|
+
def __init__(
|
|
19
|
+
self, geometry: PileGeometry, pile_type: PileType, name: str | None = None
|
|
20
|
+
):
|
|
21
|
+
"""
|
|
22
|
+
Represents all properties of a pile.
|
|
23
|
+
|
|
24
|
+
Parameters:
|
|
25
|
+
-----------
|
|
26
|
+
geometry: PileGeometry
|
|
27
|
+
The geometry of the pile.
|
|
28
|
+
pile_type: PileType
|
|
29
|
+
The type of the pile.
|
|
30
|
+
name: str, optional
|
|
31
|
+
The name of the pile, by default None.
|
|
32
|
+
"""
|
|
33
|
+
self._geometry = geometry
|
|
34
|
+
self._pile_type = pile_type
|
|
35
|
+
self._name = name
|
|
36
|
+
|
|
37
|
+
@classmethod
|
|
38
|
+
def from_api_response(cls, pile_properties: dict) -> PileProperties:
|
|
39
|
+
"""
|
|
40
|
+
Instantiates a PileProperties from a response dictionary.
|
|
41
|
+
|
|
42
|
+
Parameters:
|
|
43
|
+
-----------
|
|
44
|
+
pile_properties: dict
|
|
45
|
+
A dictionary that is retrieved from the API response payload at "/pile_properties".
|
|
46
|
+
|
|
47
|
+
Returns:
|
|
48
|
+
--------
|
|
49
|
+
PileProperties
|
|
50
|
+
A pile properties object.
|
|
51
|
+
"""
|
|
52
|
+
return cls(
|
|
53
|
+
geometry=PileGeometry.from_api_response(pile_properties["geometry"]),
|
|
54
|
+
pile_type=PileType.from_api_response(pile_properties["pile_type"]),
|
|
55
|
+
name=pile_properties.get("name"),
|
|
56
|
+
)
|
|
57
|
+
|
|
58
|
+
@property
|
|
59
|
+
def geometry(self) -> PileGeometry:
|
|
60
|
+
"""The geometry of the pile."""
|
|
61
|
+
return self._geometry
|
|
62
|
+
|
|
63
|
+
@property
|
|
64
|
+
def pile_type(self) -> PileType:
|
|
65
|
+
"""The type of the pile."""
|
|
66
|
+
return self._pile_type
|
|
67
|
+
|
|
68
|
+
@property
|
|
69
|
+
def name(self) -> str | None:
|
|
70
|
+
"""The name of the pile."""
|
|
71
|
+
return self._name
|
|
72
|
+
|
|
73
|
+
def serialize_payload(self) -> Dict[str, dict | str]:
|
|
74
|
+
"""
|
|
75
|
+
Serialize the pile properties to a dictionary payload for the API.
|
|
76
|
+
|
|
77
|
+
Returns:
|
|
78
|
+
A dictionary payload containing the geometry, pile type, and name (if set).
|
|
79
|
+
"""
|
|
80
|
+
payload: Dict[str, dict | str] = {
|
|
81
|
+
"geometry": self.geometry.serialize_payload(),
|
|
82
|
+
"pile_type": self.pile_type.serialize_payload(),
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
if self.name is not None:
|
|
86
|
+
payload["name"] = self.name
|
|
87
|
+
|
|
88
|
+
return payload
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
def create_basic_pile(
|
|
92
|
+
pile_shape: str,
|
|
93
|
+
pile_name: str | None = None,
|
|
94
|
+
main_type: str | None = None,
|
|
95
|
+
specification: str | int | float | None = None,
|
|
96
|
+
installation: str | None = None,
|
|
97
|
+
height_base: float | None = None,
|
|
98
|
+
core_secondary_dimension: float | None = None,
|
|
99
|
+
core_tertiary_dimension: float | None = None,
|
|
100
|
+
base_secondary_dimension: float | None = None,
|
|
101
|
+
base_tertiary_dimension: float | None = None,
|
|
102
|
+
core_diameter: float | None = None,
|
|
103
|
+
base_diameter: float | None = None,
|
|
104
|
+
pile_material: str | None = None,
|
|
105
|
+
custom_material: dict | None = None,
|
|
106
|
+
settlement_curve: int | None = None,
|
|
107
|
+
adhesion: float | None = None,
|
|
108
|
+
alpha_p: float | None = None,
|
|
109
|
+
alpha_s_clay: float | None = None,
|
|
110
|
+
alpha_s_sand: float | None = None,
|
|
111
|
+
beta_p: float | None = None,
|
|
112
|
+
pile_tip_factor_s: float | None = None,
|
|
113
|
+
is_auger: bool | None = None,
|
|
114
|
+
is_low_vibrating: bool | None = None,
|
|
115
|
+
negative_fr_delta_factor: float | None = None,
|
|
116
|
+
) -> PileProperties:
|
|
117
|
+
"""
|
|
118
|
+
Create a basic pile with the provided parameters.
|
|
119
|
+
A "basic" pile is a pile with a basic geometry, containing at most 2 components,
|
|
120
|
+
namely a core component and an optional shell/widened-base component.
|
|
121
|
+
|
|
122
|
+
Parameters
|
|
123
|
+
----------
|
|
124
|
+
pile_shape : str
|
|
125
|
+
The shape of the pile. Either "round" or "rect".
|
|
126
|
+
pile_name : str, optional
|
|
127
|
+
The name of the pile, by default None.
|
|
128
|
+
main_type : str, optional
|
|
129
|
+
The main type of the standard pile type definition, by default None.
|
|
130
|
+
specification : str | int | float, optional
|
|
131
|
+
The specification of the standard pile type definition, by default None.
|
|
132
|
+
Required if `main_type` is provided.
|
|
133
|
+
installation : str, optional
|
|
134
|
+
The installation of the standard pile type definition, by default None.
|
|
135
|
+
height_base : float, optional
|
|
136
|
+
The height [m] of the base component, by default None.
|
|
137
|
+
Required if base dimensions are provided.
|
|
138
|
+
core_secondary_dimension : float, optional
|
|
139
|
+
The largest dimension [m] of the core component's cross-section, by default None.
|
|
140
|
+
Required for rectangular piles.
|
|
141
|
+
core_tertiary_dimension : float, optional
|
|
142
|
+
The smallest dimension [m] of the core component's cross-section, by default None.
|
|
143
|
+
base_secondary_dimension : float, optional
|
|
144
|
+
The largest dimension [m] of the base/shell component's cross-section, by default None.
|
|
145
|
+
base_tertiary_dimension : float, optional
|
|
146
|
+
The smallest dimension [m] of the base/shell component's cross-section, by default None.
|
|
147
|
+
core_diameter : float, optional
|
|
148
|
+
The diameter [m] of the core component's cross-section, by default None.
|
|
149
|
+
Required for round piles.
|
|
150
|
+
base_diameter : float, optional
|
|
151
|
+
The diameter [m] of the base/shell component's cross-section, by default None.
|
|
152
|
+
pile_material : str, optional
|
|
153
|
+
The material of the pile, by default None.
|
|
154
|
+
Required if no standard pile type was specified.
|
|
155
|
+
custom_material : dict, optional
|
|
156
|
+
A custom material for the pile, by default None.
|
|
157
|
+
settlement_curve : int, optional
|
|
158
|
+
The settlement curve of the pile, by default None.
|
|
159
|
+
Required if no standard pile type was specified.
|
|
160
|
+
adhesion : float, optional
|
|
161
|
+
The adhesion of the pile, by default None.
|
|
162
|
+
Required if no standard pile type was specified.
|
|
163
|
+
alpha_p : float, optional
|
|
164
|
+
The alpha_p of the pile, by default None.
|
|
165
|
+
Required if no standard pile type was specified.
|
|
166
|
+
alpha_s_clay : float, optional
|
|
167
|
+
The alpha_s_clay of the pile, by default None.
|
|
168
|
+
Required if no standard pile type was specified.
|
|
169
|
+
alpha_s_sand : float, optional
|
|
170
|
+
The alpha_s_sand of the pile, by default None.
|
|
171
|
+
Required if no standard pile type was specified.
|
|
172
|
+
beta_p : float, optional
|
|
173
|
+
The beta_p of the pile, by default None.
|
|
174
|
+
Required if no standard pile type was specified.
|
|
175
|
+
pile_tip_factor_s : float, optional
|
|
176
|
+
The pile tip factor s of the pile, by default None.
|
|
177
|
+
Required if no standard pile type was specified.
|
|
178
|
+
is_auger : bool, optional
|
|
179
|
+
Whether the pile is an auger pile, by default None.
|
|
180
|
+
Required if no standard pile type was specified.
|
|
181
|
+
is_low_vibrating : bool, optional
|
|
182
|
+
Whether the pile is low vibrating, by default None.
|
|
183
|
+
Required if no standard pile type was specified.
|
|
184
|
+
negative_fr_delta_factor : float, optional
|
|
185
|
+
The negative friction delta factor of the pile, by default None.
|
|
186
|
+
Required if no standard pile type was specified.
|
|
187
|
+
|
|
188
|
+
Returns
|
|
189
|
+
-------
|
|
190
|
+
PileProperties
|
|
191
|
+
The pile properties object.
|
|
192
|
+
"""
|
|
193
|
+
materials = [
|
|
194
|
+
PileMaterial(**material_value) for material_value in MATERIALS.values() # type: ignore
|
|
195
|
+
]
|
|
196
|
+
|
|
197
|
+
if custom_material is not None:
|
|
198
|
+
materials = [PileMaterial(**custom_material)]
|
|
199
|
+
|
|
200
|
+
if pile_shape == "round":
|
|
201
|
+
if core_diameter is None:
|
|
202
|
+
raise ValueError("`core_diameter` must be provided for a round pile.")
|
|
203
|
+
|
|
204
|
+
components: List[RoundPileGeometryComponent | RectPileGeometryComponent] = [
|
|
205
|
+
RoundPileGeometryComponent(
|
|
206
|
+
diameter=core_diameter,
|
|
207
|
+
primary_dimension=PrimaryPileComponentDimension(
|
|
208
|
+
length=None,
|
|
209
|
+
),
|
|
210
|
+
material=pile_material,
|
|
211
|
+
)
|
|
212
|
+
]
|
|
213
|
+
|
|
214
|
+
if base_diameter is not None:
|
|
215
|
+
components.append(
|
|
216
|
+
RoundPileGeometryComponent(
|
|
217
|
+
diameter=base_diameter,
|
|
218
|
+
primary_dimension=PrimaryPileComponentDimension(
|
|
219
|
+
length=height_base,
|
|
220
|
+
),
|
|
221
|
+
material=pile_material,
|
|
222
|
+
)
|
|
223
|
+
)
|
|
224
|
+
|
|
225
|
+
elif pile_shape in ["rect", "rectangle"]:
|
|
226
|
+
if core_secondary_dimension is None:
|
|
227
|
+
raise ValueError(
|
|
228
|
+
"`core_secondary_dimension` must be provided for a rectangular pile."
|
|
229
|
+
)
|
|
230
|
+
|
|
231
|
+
components = [
|
|
232
|
+
RectPileGeometryComponent(
|
|
233
|
+
primary_dimension=PrimaryPileComponentDimension(length=None),
|
|
234
|
+
secondary_dimension=core_secondary_dimension,
|
|
235
|
+
tertiary_dimension=core_tertiary_dimension,
|
|
236
|
+
material=pile_material,
|
|
237
|
+
)
|
|
238
|
+
]
|
|
239
|
+
|
|
240
|
+
if base_secondary_dimension is not None:
|
|
241
|
+
components.append(
|
|
242
|
+
RectPileGeometryComponent(
|
|
243
|
+
secondary_dimension=base_secondary_dimension,
|
|
244
|
+
tertiary_dimension=base_tertiary_dimension,
|
|
245
|
+
primary_dimension=PrimaryPileComponentDimension(
|
|
246
|
+
length=height_base,
|
|
247
|
+
),
|
|
248
|
+
material=pile_material,
|
|
249
|
+
)
|
|
250
|
+
)
|
|
251
|
+
|
|
252
|
+
else:
|
|
253
|
+
raise ValueError(f"Invalid pile shape: {pile_shape}")
|
|
254
|
+
|
|
255
|
+
geometry = PileGeometry(
|
|
256
|
+
components=components,
|
|
257
|
+
materials=materials,
|
|
258
|
+
pile_tip_factor_s=pile_tip_factor_s,
|
|
259
|
+
beta_p=beta_p,
|
|
260
|
+
)
|
|
261
|
+
|
|
262
|
+
if main_type is not None:
|
|
263
|
+
if specification is None:
|
|
264
|
+
raise ValueError("Specification must be provided if main type is provided.")
|
|
265
|
+
|
|
266
|
+
standard_pile: Dict[str, str | int] | None = {
|
|
267
|
+
"main_type": main_type,
|
|
268
|
+
"specification": int(specification),
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
if installation is not None:
|
|
272
|
+
standard_pile["installation"] = installation # type: ignore
|
|
273
|
+
|
|
274
|
+
else:
|
|
275
|
+
standard_pile = None
|
|
276
|
+
|
|
277
|
+
pile_type = PileType(
|
|
278
|
+
standard_pile=standard_pile,
|
|
279
|
+
alpha_s_sand=alpha_s_sand,
|
|
280
|
+
alpha_s_clay=alpha_s_clay,
|
|
281
|
+
alpha_p=alpha_p,
|
|
282
|
+
alpha_t_sand=None,
|
|
283
|
+
settlement_curve=settlement_curve,
|
|
284
|
+
negative_fr_delta_factor=negative_fr_delta_factor,
|
|
285
|
+
adhesion=adhesion,
|
|
286
|
+
is_low_vibrating=is_low_vibrating,
|
|
287
|
+
is_auger=is_auger,
|
|
288
|
+
)
|
|
289
|
+
|
|
290
|
+
return PileProperties(geometry=geometry, pile_type=pile_type, name=pile_name)
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import Dict
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class PileType:
|
|
7
|
+
"""The PileType class represents the type of a pile."""
|
|
8
|
+
|
|
9
|
+
def __init__(
|
|
10
|
+
self,
|
|
11
|
+
standard_pile: Dict[str, str | int] | None = None,
|
|
12
|
+
alpha_s_sand: float | None = None,
|
|
13
|
+
alpha_s_clay: float | None = None,
|
|
14
|
+
alpha_p: float | None = None,
|
|
15
|
+
alpha_t_sand: float | None = None,
|
|
16
|
+
settlement_curve: int | None = None,
|
|
17
|
+
negative_fr_delta_factor: float | None = None,
|
|
18
|
+
adhesion: float | None = None,
|
|
19
|
+
is_low_vibrating: bool | None = None,
|
|
20
|
+
is_auger: bool | None = None,
|
|
21
|
+
):
|
|
22
|
+
"""
|
|
23
|
+
Represents the type of a pile.
|
|
24
|
+
|
|
25
|
+
Parameters:
|
|
26
|
+
-----------
|
|
27
|
+
standard_pile : dict, optional
|
|
28
|
+
The standard pile definition of the pile type (if applicable), by default None.
|
|
29
|
+
alpha_s_sand : float, optional
|
|
30
|
+
The alpha_s_sand value of the pile type, by default None.
|
|
31
|
+
alpha_s_clay : float, optional
|
|
32
|
+
The alpha_s_clay value of the pile type, by default None.
|
|
33
|
+
alpha_p : float, optional
|
|
34
|
+
The alpha_p value of the pile type, by default None.
|
|
35
|
+
alpha_t_sand : float, optional
|
|
36
|
+
The alpha_t_sand value of the pile type, by default None.
|
|
37
|
+
settlement_curve : int, optional
|
|
38
|
+
The settlement curve of the pile type, by default None.
|
|
39
|
+
negative_fr_delta_factor : float, optional
|
|
40
|
+
The negative_fr_delta_factor value of the pile type, by default None.
|
|
41
|
+
adhesion : float, optional
|
|
42
|
+
The adhesion value of the pile type, by default None.
|
|
43
|
+
is_low_vibrating : bool, optional
|
|
44
|
+
The is_low_vibrating value of the pile type, by default None.
|
|
45
|
+
is_auger : bool, optional
|
|
46
|
+
The is_auger value of the pile type, by default None.
|
|
47
|
+
"""
|
|
48
|
+
self._standard_pile = standard_pile
|
|
49
|
+
self._alpha_s_sand = alpha_s_sand
|
|
50
|
+
self._alpha_s_clay = alpha_s_clay
|
|
51
|
+
self._alpha_p = alpha_p
|
|
52
|
+
self._alpha_t_sand = alpha_t_sand
|
|
53
|
+
self._settlement_curve = settlement_curve
|
|
54
|
+
self._negative_fr_delta_factor = negative_fr_delta_factor
|
|
55
|
+
self._adhesion = adhesion
|
|
56
|
+
self._is_low_vibrating = is_low_vibrating
|
|
57
|
+
self._is_auger = is_auger
|
|
58
|
+
|
|
59
|
+
@classmethod
|
|
60
|
+
def from_api_response(cls, pile_type: dict) -> PileType:
|
|
61
|
+
"""
|
|
62
|
+
Instantiates a PileType from a pile type object in the API response payload.
|
|
63
|
+
|
|
64
|
+
Parameters:
|
|
65
|
+
-----------
|
|
66
|
+
pile_type: dict
|
|
67
|
+
A dictionary that is retrieved from the API response payload at "/pile_properties/pile_type".
|
|
68
|
+
|
|
69
|
+
Returns:
|
|
70
|
+
--------
|
|
71
|
+
PileType
|
|
72
|
+
A pile type.
|
|
73
|
+
"""
|
|
74
|
+
return cls(
|
|
75
|
+
standard_pile=pile_type.get("standard_pile"),
|
|
76
|
+
alpha_s_sand=pile_type["properties"]["alpha_s_sand"],
|
|
77
|
+
alpha_s_clay=pile_type["properties"]["alpha_s_clay"],
|
|
78
|
+
alpha_p=pile_type["properties"]["alpha_p"],
|
|
79
|
+
alpha_t_sand=pile_type["properties"]["alpha_t_sand"],
|
|
80
|
+
settlement_curve=pile_type["properties"]["settlement_curve"],
|
|
81
|
+
negative_fr_delta_factor=pile_type["properties"][
|
|
82
|
+
"negative_fr_delta_factor"
|
|
83
|
+
],
|
|
84
|
+
adhesion=pile_type["properties"]["adhesion"],
|
|
85
|
+
is_low_vibrating=pile_type["properties"]["is_low_vibrating"],
|
|
86
|
+
is_auger=pile_type["properties"]["is_auger"],
|
|
87
|
+
)
|
|
88
|
+
|
|
89
|
+
@property
|
|
90
|
+
def standard_pile(self) -> Dict[str, str | int] | None:
|
|
91
|
+
"""The standard pile definition of the pile type (if applicable)"""
|
|
92
|
+
return self._standard_pile
|
|
93
|
+
|
|
94
|
+
@property
|
|
95
|
+
def alpha_s_sand(self) -> float | None:
|
|
96
|
+
"""The alpha_s_sand value of the pile type"""
|
|
97
|
+
return self._alpha_s_sand
|
|
98
|
+
|
|
99
|
+
@property
|
|
100
|
+
def alpha_s_clay(self) -> float | None:
|
|
101
|
+
"""The alpha_s_clay value of the pile type"""
|
|
102
|
+
return self._alpha_s_clay
|
|
103
|
+
|
|
104
|
+
@property
|
|
105
|
+
def alpha_p(self) -> float | None:
|
|
106
|
+
"""The alpha_p value of the pile type"""
|
|
107
|
+
return self._alpha_p
|
|
108
|
+
|
|
109
|
+
@property
|
|
110
|
+
def alpha_t_sand(self) -> float | None:
|
|
111
|
+
"""The alpha_t_sand value of the pile type"""
|
|
112
|
+
return self._alpha_t_sand
|
|
113
|
+
|
|
114
|
+
@property
|
|
115
|
+
def settlement_curve(self) -> int | None:
|
|
116
|
+
"""The settlement curve of the pile type"""
|
|
117
|
+
return self._settlement_curve
|
|
118
|
+
|
|
119
|
+
@property
|
|
120
|
+
def negative_fr_delta_factor(self) -> float | None:
|
|
121
|
+
"""The negative_fr_delta_factor value of the pile type"""
|
|
122
|
+
return self._negative_fr_delta_factor
|
|
123
|
+
|
|
124
|
+
@property
|
|
125
|
+
def adhesion(self) -> float | None:
|
|
126
|
+
"""The adhesion value of the pile type"""
|
|
127
|
+
return self._adhesion
|
|
128
|
+
|
|
129
|
+
@property
|
|
130
|
+
def is_low_vibrating(self) -> bool | None:
|
|
131
|
+
"""The is_low_vibrating value of the pile type"""
|
|
132
|
+
return self._is_low_vibrating
|
|
133
|
+
|
|
134
|
+
@property
|
|
135
|
+
def is_auger(self) -> bool | None:
|
|
136
|
+
"""The is_auger value of the pile type"""
|
|
137
|
+
return self._is_auger
|
|
138
|
+
|
|
139
|
+
def serialize_payload(self) -> Dict[str, str | dict]:
|
|
140
|
+
"""
|
|
141
|
+
Serialize the pile type to a dictionary payload for the API.
|
|
142
|
+
|
|
143
|
+
Returns:
|
|
144
|
+
A dictionary payload containing the standard pile (if set), alpha_s_sand, alpha_s_clay, alpha_p,
|
|
145
|
+
alpha_t_sand, settlement curve, negative_fr_delta_factor, adhesion, is_low_vibrating, and is_auger.
|
|
146
|
+
"""
|
|
147
|
+
payload: Dict[str, str | dict] = {}
|
|
148
|
+
|
|
149
|
+
if self.standard_pile is not None:
|
|
150
|
+
payload["standard_pile"] = {
|
|
151
|
+
"main_type": str(self.standard_pile["main_type"]),
|
|
152
|
+
"specification": str(self.standard_pile["specification"]),
|
|
153
|
+
}
|
|
154
|
+
if (
|
|
155
|
+
"installation" in self.standard_pile
|
|
156
|
+
and self.standard_pile["installation"] is not None
|
|
157
|
+
):
|
|
158
|
+
payload["standard_pile"]["installation"] = str( # type: ignore
|
|
159
|
+
self.standard_pile["installation"]
|
|
160
|
+
)
|
|
161
|
+
|
|
162
|
+
custom_type_properties: Dict[str, float | bool] = {}
|
|
163
|
+
|
|
164
|
+
if self.alpha_s_sand is not None:
|
|
165
|
+
custom_type_properties["alpha_s_sand"] = self.alpha_s_sand
|
|
166
|
+
|
|
167
|
+
if self.alpha_s_clay is not None:
|
|
168
|
+
custom_type_properties["alpha_s_clay"] = self.alpha_s_clay
|
|
169
|
+
|
|
170
|
+
if self.alpha_p is not None:
|
|
171
|
+
custom_type_properties["alpha_p"] = self.alpha_p
|
|
172
|
+
|
|
173
|
+
if self.alpha_t_sand is not None:
|
|
174
|
+
custom_type_properties["alpha_t_sand"] = self.alpha_t_sand
|
|
175
|
+
|
|
176
|
+
if self.settlement_curve is not None:
|
|
177
|
+
custom_type_properties["settlement_curve"] = self.settlement_curve
|
|
178
|
+
|
|
179
|
+
if self.negative_fr_delta_factor is not None:
|
|
180
|
+
custom_type_properties[
|
|
181
|
+
"negative_fr_delta_factor"
|
|
182
|
+
] = self.negative_fr_delta_factor
|
|
183
|
+
|
|
184
|
+
if self.adhesion is not None:
|
|
185
|
+
custom_type_properties["adhesion"] = self.adhesion
|
|
186
|
+
|
|
187
|
+
if self.is_low_vibrating is not None:
|
|
188
|
+
custom_type_properties["is_low_vibrating"] = self.is_low_vibrating
|
|
189
|
+
|
|
190
|
+
if self.is_auger is not None:
|
|
191
|
+
custom_type_properties["is_auger"] = self.is_auger
|
|
192
|
+
|
|
193
|
+
if len(custom_type_properties.keys()) > 0:
|
|
194
|
+
payload["custom_properties"] = custom_type_properties
|
|
195
|
+
|
|
196
|
+
return payload
|
pypilecore/input/__init__.py
CHANGED
|
@@ -6,11 +6,9 @@ from pypilecore.input.multi_cpt import (
|
|
|
6
6
|
create_multi_cpt_payload,
|
|
7
7
|
create_multi_cpt_report_payload,
|
|
8
8
|
)
|
|
9
|
-
from pypilecore.input.pile_properties import create_pile_properties_payload
|
|
10
9
|
from pypilecore.input.soil_properties import create_soil_properties_payload
|
|
11
10
|
|
|
12
11
|
__all__ = [
|
|
13
|
-
"create_pile_properties_payload",
|
|
14
12
|
"create_soil_properties_payload",
|
|
15
13
|
"create_multi_cpt_payload",
|
|
16
14
|
"create_grouper_payload",
|
pypilecore/input/multi_cpt.py
CHANGED
|
@@ -6,7 +6,7 @@ from typing import Dict, List, Literal, Mapping, Sequence, Tuple
|
|
|
6
6
|
|
|
7
7
|
from pygef.cpt import CPTData
|
|
8
8
|
|
|
9
|
-
from pypilecore.
|
|
9
|
+
from pypilecore.common.piles import PileProperties
|
|
10
10
|
from pypilecore.input.soil_properties import create_soil_properties_payload
|
|
11
11
|
|
|
12
12
|
|
|
@@ -15,10 +15,7 @@ def create_multi_cpt_payload(
|
|
|
15
15
|
cptdata_objects: List[CPTData],
|
|
16
16
|
classify_tables: Dict[str, dict],
|
|
17
17
|
groundwater_level_nap: float,
|
|
18
|
-
|
|
19
|
-
specification: Literal["1", "2", "3", "4", "5", "6", "7"],
|
|
20
|
-
installation: Literal["A", "B", "C", "D", "E", "F", "G"],
|
|
21
|
-
pile_shape: Literal["round", "rect"],
|
|
18
|
+
pile: PileProperties,
|
|
22
19
|
friction_range_strategy: Literal[
|
|
23
20
|
"manual", "lower_bound", "settlement_driven"
|
|
24
21
|
] = "lower_bound",
|
|
@@ -43,24 +40,6 @@ def create_multi_cpt_payload(
|
|
|
43
40
|
]
|
|
44
41
|
| None = None,
|
|
45
42
|
individual_ocr: Mapping[str, float] | None = None,
|
|
46
|
-
diameter_base: float | None = None,
|
|
47
|
-
diameter_shaft: float | None = None,
|
|
48
|
-
width_base_large: float | None = None,
|
|
49
|
-
width_base_small: float | None = None,
|
|
50
|
-
width_shaft_large: float | None = None,
|
|
51
|
-
width_shaft_small: float | None = None,
|
|
52
|
-
height_base: float | None = None,
|
|
53
|
-
settlement_curve: float | None = None,
|
|
54
|
-
adhesion: float | None = None,
|
|
55
|
-
alpha_p: float | None = None,
|
|
56
|
-
alpha_s_clay: float | None = None,
|
|
57
|
-
alpha_s_sand: float | None = None,
|
|
58
|
-
beta_p: float | None = None,
|
|
59
|
-
pile_tip_factor_s: float | None = None,
|
|
60
|
-
elastic_modulus: float | None = None,
|
|
61
|
-
is_auger: float | None = None,
|
|
62
|
-
is_low_vibrating: float | None = None,
|
|
63
|
-
negative_fr_delta_factor: float | None = None,
|
|
64
43
|
use_almere_rules: bool = False,
|
|
65
44
|
overrule_xi: float | None = None,
|
|
66
45
|
gamma_f_nk: float = 1.0,
|
|
@@ -112,19 +91,13 @@ def create_multi_cpt_payload(
|
|
|
112
91
|
|
|
113
92
|
groundwater_level_nap:
|
|
114
93
|
The groundwater level. Unit: [m] w.r.t. NAP.
|
|
115
|
-
|
|
116
|
-
|
|
94
|
+
pile:
|
|
95
|
+
A PileProperties object.
|
|
117
96
|
friction_range_strategy:
|
|
118
97
|
Sets the method to determine the sleeve friction zones on the pile. The soil
|
|
119
98
|
friction in the positive zone contributes to the bearing capacity, while the
|
|
120
99
|
negative zone adds an extra load on the pile. Accepted values: "manual",
|
|
121
100
|
"lower_bound" (default) or "settlement_driven".
|
|
122
|
-
specification:
|
|
123
|
-
The equaly named entry in the "pile_type_specification" settings.
|
|
124
|
-
installation:
|
|
125
|
-
The equaly named entry in the "pile_type_specification" settings.
|
|
126
|
-
pile_shape:
|
|
127
|
-
The shape of the pile.
|
|
128
101
|
stiff_construction:
|
|
129
102
|
Set to True if it's a stiff costruction. This will have influence on the xi factor
|
|
130
103
|
if you don't overrule it. Default = False.
|
|
@@ -197,66 +170,6 @@ def create_multi_cpt_payload(
|
|
|
197
170
|
A dictionary, mapping ``CPTData.alias`` values to Over-Consolidation-Ratio [-]
|
|
198
171
|
values of the foundation layer. This will overrule the general `ocr` setting for
|
|
199
172
|
these specific CPTs only.
|
|
200
|
-
diameter_base:
|
|
201
|
-
Pile base diameter [m].
|
|
202
|
-
Only relevant if ``pile_shape`` = "round".
|
|
203
|
-
diameter_shaft:
|
|
204
|
-
Pile shaft diameter [m].
|
|
205
|
-
Only relevant if ``pile_shape`` = "round".
|
|
206
|
-
width_base_large:
|
|
207
|
-
Largest dimension of the pile base [m].
|
|
208
|
-
Only relevant if ``pile_shape`` = "rect".
|
|
209
|
-
width_base_small:
|
|
210
|
-
Smallest dimension of the pile base [m].
|
|
211
|
-
Only relevant if ``pile_shape`` = "rect".
|
|
212
|
-
width_shaft_large:
|
|
213
|
-
Largest dimension of the pile shaft [m].
|
|
214
|
-
Only relevant if ``pile_shape`` = "rect".
|
|
215
|
-
width_shaft_small:
|
|
216
|
-
Smallest dimension of the pile shaft [m].
|
|
217
|
-
Only relevant if ``pile_shape`` = "rect".
|
|
218
|
-
height_base:
|
|
219
|
-
Height of pile base [m]. If None, a pile with constant dimension is inferred.
|
|
220
|
-
Cannot be None if diameter_base and diameter_shaft are unequal.
|
|
221
|
-
settlement_curve:
|
|
222
|
-
Settlement lines for figures 7.n and 7.o of NEN-9997-1 As defined in table 7.c
|
|
223
|
-
of NEN-9997-1. The value is inferred from the pile_type_specifications, but can
|
|
224
|
-
be overwritten.
|
|
225
|
-
adhesion:
|
|
226
|
-
Optional adhesion value [kPa], use it if the pile shaft has undergone a special
|
|
227
|
-
treatment. Examples: - adhesion = 50 kN/m2 for synthetic coating - adhesion = 20
|
|
228
|
-
kN/m2 for bentonite - adhesion = 10 kN/m2 for bitumen coating See 7.3.2.2(d) of
|
|
229
|
-
NEN 9997-1 for examples.
|
|
230
|
-
alpha_p:
|
|
231
|
-
Alpha p factor used in pile tip resistance calculation. The value is inferred
|
|
232
|
-
from the pile_type_specifications, but can be overwritten.
|
|
233
|
-
alpha_s_clay:
|
|
234
|
-
Alpha s factor for soft layers used in the positive friction calculation. If
|
|
235
|
-
None the factor is determined as specified in table 7.d of NEN 9997-1.
|
|
236
|
-
alpha_s_sand:
|
|
237
|
-
Alpha s factor for coarse layers used in the positive friction calculation. The
|
|
238
|
-
value is inferred from the pile_type_specifications, but can be overwritten.
|
|
239
|
-
beta_p:
|
|
240
|
-
Factor s used in pile tip resistance calculation as per NEN 9997-1 7.6.2.3 (h).
|
|
241
|
-
The value is inferred from the pile dimension properties, but can be overwritten.
|
|
242
|
-
pile_tip_factor_s:
|
|
243
|
-
Factor s used in pile tip resistance calculation as per NEN 9997-1 7.6.2.3 (h).
|
|
244
|
-
The value is inferred from the pile dimension properties, but can be overwritten.
|
|
245
|
-
elastic_modulus:
|
|
246
|
-
Modulus of elasticity of the pile [Mpa]. The value is inferred from the
|
|
247
|
-
pile_type_specifications, but can be overwritten.
|
|
248
|
-
is_auger:
|
|
249
|
-
Determines weather the pile the pile is an auger pile or not. The value is
|
|
250
|
-
inferred from the pile_type_specifications, but can be overwritten.
|
|
251
|
-
is_low_vibrating:
|
|
252
|
-
Determines weather the pile has an installation type with low vibration. The
|
|
253
|
-
value is inferred from the pile_type_specifications, but can be overwritten.
|
|
254
|
-
negative_fr_delta_factor:
|
|
255
|
-
factor * φ = δ. This parameter will be multiplied with phi to get the delta
|
|
256
|
-
parameter used in negative friction calculation according to NEN-9997-1 7.3.2.2
|
|
257
|
-
(e). Typically values are 1.0 for piles cast in place, and 0.75 for other pile
|
|
258
|
-
types. The value is inferred from the pile_type_specifications, but can be
|
|
259
|
-
overwritten.
|
|
260
173
|
use_almere_rules:
|
|
261
174
|
If set to True the contribution, produced by the positive shaft friction, to the
|
|
262
175
|
total bearing capacity is limited to at most 75% the contribution provided by
|
|
@@ -287,9 +200,8 @@ def create_multi_cpt_payload(
|
|
|
287
200
|
Raises
|
|
288
201
|
------
|
|
289
202
|
ValueError:
|
|
290
|
-
-
|
|
291
|
-
-
|
|
292
|
-
- if `pile_shape` not in ["rect", "round"]
|
|
203
|
+
- If `excavation_depth_nap` is not None and `excavation_param_t` is None.
|
|
204
|
+
- If both `relative_pile_load` and `pile_load_sls` are None.
|
|
293
205
|
"""
|
|
294
206
|
# Input validation
|
|
295
207
|
if excavation_depth_nap is not None and excavation_param_t is None:
|
|
@@ -312,34 +224,10 @@ def create_multi_cpt_payload(
|
|
|
312
224
|
individual_positive_friction_range_nap=individual_positive_friction_range_nap,
|
|
313
225
|
individual_ocr=individual_ocr,
|
|
314
226
|
)
|
|
315
|
-
pile_properties = create_pile_properties_payload(
|
|
316
|
-
pile_type=str(pile_type),
|
|
317
|
-
specification=str(specification),
|
|
318
|
-
installation=str(installation),
|
|
319
|
-
pile_shape=pile_shape,
|
|
320
|
-
diameter_base=diameter_base,
|
|
321
|
-
diameter_shaft=diameter_shaft,
|
|
322
|
-
width_base_large=width_base_large,
|
|
323
|
-
width_base_small=width_base_small,
|
|
324
|
-
width_shaft_large=width_shaft_large,
|
|
325
|
-
width_shaft_small=width_shaft_small,
|
|
326
|
-
height_base=height_base,
|
|
327
|
-
settlement_curve=settlement_curve,
|
|
328
|
-
adhesion=adhesion,
|
|
329
|
-
alpha_p=alpha_p,
|
|
330
|
-
alpha_s_clay=alpha_s_clay,
|
|
331
|
-
alpha_s_sand=alpha_s_sand,
|
|
332
|
-
beta_p=beta_p,
|
|
333
|
-
pile_tip_factor_s=pile_tip_factor_s,
|
|
334
|
-
elastic_modulus=elastic_modulus,
|
|
335
|
-
is_auger=is_auger,
|
|
336
|
-
is_low_vibrating=is_low_vibrating,
|
|
337
|
-
negative_fr_delta_factor=negative_fr_delta_factor,
|
|
338
|
-
)
|
|
339
227
|
multi_cpt_payload: dict = dict(
|
|
340
228
|
pile_tip_levels_nap=list(pile_tip_levels_nap),
|
|
341
229
|
list_soil_properties=soil_properties_list,
|
|
342
|
-
pile_properties=
|
|
230
|
+
pile_properties=pile.serialize_payload(),
|
|
343
231
|
friction_range_strategy=friction_range_strategy,
|
|
344
232
|
pile_head_level_nap=pile_head_level_nap,
|
|
345
233
|
stiff_construction=stiff_construction,
|