geolysis 0.13.0__tar.gz → 0.15.0__tar.gz
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.
- {geolysis-0.13.0 → geolysis-0.15.0}/PKG-INFO +1 -1
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/__init__.py +1 -1
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/ubc/__init__.py +13 -16
- geolysis-0.15.0/geolysis/exceptions.py +3 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/utils/__init__.py +1 -1
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis.egg-info/PKG-INFO +1 -1
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis.egg-info/SOURCES.txt +1 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/tests/test_foundation.py +7 -4
- {geolysis-0.13.0 → geolysis-0.15.0}/tests/test_spt.py +15 -12
- {geolysis-0.13.0 → geolysis-0.15.0}/LICENSE.txt +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/README.md +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/__init__.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/abc/__init__.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/abc/_cohl/__init__.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/abc/_cohl/_core.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/abc/_cohl/bowles_abc.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/abc/_cohl/meyerhof_abc.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/abc/_cohl/terzaghi_abc.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/ubc/_core.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/ubc/_terzaghi_ubc.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/bearing_capacity/ubc/_vesic_ubc.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/foundation.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/soil_classifier.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/spt.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis/utils/math.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis.egg-info/dependency_links.txt +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis.egg-info/requires.txt +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/geolysis.egg-info/top_level.txt +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/pyproject.toml +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/setup.cfg +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/setup.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/tests/test_docs.py +0 -0
- {geolysis-0.13.0 → geolysis-0.15.0}/tests/test_soil_classifier.py +0 -0
@@ -33,9 +33,6 @@ class UBCType(AbstractStrEnum):
|
|
33
33
|
the ultimate bearing capacity of soil.
|
34
34
|
"""
|
35
35
|
|
36
|
-
HANSEN = enum.auto()
|
37
|
-
"""Hansen's method for calculating ultimate bearing capacity."""
|
38
|
-
|
39
36
|
TERZAGHI = enum.auto()
|
40
37
|
"""Terzaghi's method for calculating ultimate bearing capacity."""
|
41
38
|
|
@@ -56,19 +53,19 @@ ubc_classes = {
|
|
56
53
|
|
57
54
|
@validate_params
|
58
55
|
def create_ubc_4_all_soil_types(
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
56
|
+
friction_angle: float,
|
57
|
+
cohesion: float,
|
58
|
+
moist_unit_wgt: float,
|
59
|
+
depth: float,
|
60
|
+
width: float,
|
61
|
+
length: Optional[float] = None,
|
62
|
+
saturated_unit_wgt: float = 20.5,
|
63
|
+
eccentricity: float = 0.0,
|
64
|
+
ground_water_level: Optional[float] = inf,
|
65
|
+
load_angle: float = 0.0,
|
66
|
+
apply_local_shear: bool = False,
|
67
|
+
shape: Shape | str = "square",
|
68
|
+
ubc_type: Annotated[UBCType | str, MustBeMemberOf(UBCType)] = "vesic",
|
72
69
|
) -> UltimateBearingCapacity:
|
73
70
|
r"""A factory function that encapsulate the creation of ultimate
|
74
71
|
bearing capacity.
|
@@ -5,7 +5,7 @@ from typing import Callable
|
|
5
5
|
from .math import *
|
6
6
|
from . import math as m
|
7
7
|
|
8
|
-
__all__ = ["AbstractStrEnum", "
|
8
|
+
__all__ = ["AbstractStrEnum", "add_repr", "round_"] + m.__all__
|
9
9
|
|
10
10
|
|
11
11
|
class StrEnumMeta(enum.EnumMeta):
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import unittest
|
2
2
|
|
3
|
-
from
|
3
|
+
from geolysis.exceptions import ValidationError
|
4
4
|
|
5
5
|
from geolysis.foundation import (
|
6
6
|
CircularFooting,
|
@@ -61,7 +61,8 @@ class TestFoundation(unittest.TestCase):
|
|
61
61
|
|
62
62
|
def test_foundation_size(self):
|
63
63
|
footing = StripFooting(width=2.0)
|
64
|
-
foundation = Foundation(depth=1.5, footing_size=footing,
|
64
|
+
foundation = Foundation(depth=1.5, footing_size=footing,
|
65
|
+
eccentricity=0.1)
|
65
66
|
self.assertEqual(foundation.depth, 1.5)
|
66
67
|
self.assertEqual(foundation.width, 2.0)
|
67
68
|
self.assertEqual(foundation.length, float("inf"))
|
@@ -85,14 +86,16 @@ class TestFoundation(unittest.TestCase):
|
|
85
86
|
self.assertEqual(foundation.footing_shape, Shape.STRIP)
|
86
87
|
|
87
88
|
def test_create_foundation_square(self):
|
88
|
-
foundation = create_foundation(depth=1.5, width=2.5,
|
89
|
+
foundation = create_foundation(depth=1.5, width=2.5,
|
90
|
+
shape=Shape.SQUARE)
|
89
91
|
self.assertEqual(foundation.depth, 1.5)
|
90
92
|
self.assertEqual(foundation.width, 2.5)
|
91
93
|
self.assertEqual(foundation.length, 2.5)
|
92
94
|
self.assertEqual(foundation.footing_shape, Shape.SQUARE)
|
93
95
|
|
94
96
|
def test_create_foundation_circle(self):
|
95
|
-
foundation = create_foundation(depth=1.5, width=3.0,
|
97
|
+
foundation = create_foundation(depth=1.5, width=3.0,
|
98
|
+
shape=Shape.CIRCLE)
|
96
99
|
self.assertEqual(foundation.depth, 1.5)
|
97
100
|
self.assertEqual(foundation.width, 3.0)
|
98
101
|
self.assertEqual(foundation.length, 3.0)
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import pytest
|
2
|
-
from
|
2
|
+
from geolysis.exceptions import ValidationError
|
3
3
|
|
4
4
|
from geolysis.spt import (
|
5
5
|
DilatancyCorrection,
|
@@ -65,20 +65,22 @@ class TestEnergyCorrection:
|
|
65
65
|
],
|
66
66
|
[
|
67
67
|
(30, 0.6, 65.0, 3, HammerType.DONUT_1, SamplerType.STANDARD, 22.5),
|
68
|
-
(30, 0.6, 120.0, 5, HammerType.AUTOMATIC, SamplerType.NON_STANDARD,
|
69
|
-
|
68
|
+
(30, 0.6, 120.0, 5, HammerType.AUTOMATIC, SamplerType.NON_STANDARD,
|
69
|
+
37.5),
|
70
|
+
(
|
71
|
+
30, 0.6, 170.0, 7, HammerType.DONUT_2, SamplerType.STANDARD, 27.3),
|
70
72
|
(30, 0.6, 65.0, 12, HammerType.SAFETY, SamplerType.STANDARD, 27.5),
|
71
73
|
],
|
72
74
|
)
|
73
75
|
def test_energy_correction(
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
76
|
+
self,
|
77
|
+
rec_spt_n_val,
|
78
|
+
energy_percentage,
|
79
|
+
borehole_diameter,
|
80
|
+
rod_len,
|
81
|
+
hammer_type,
|
82
|
+
sampler_type,
|
83
|
+
expected,
|
82
84
|
):
|
83
85
|
energy_corr = EnergyCorrection(
|
84
86
|
recorded_spt_n_value=rec_spt_n_val,
|
@@ -89,7 +91,8 @@ class TestEnergyCorrection:
|
|
89
91
|
sampler_type=sampler_type,
|
90
92
|
)
|
91
93
|
|
92
|
-
assert energy_corr.standardized_spt_n_value() == pytest.approx(
|
94
|
+
assert energy_corr.standardized_spt_n_value() == pytest.approx(
|
95
|
+
expected)
|
93
96
|
|
94
97
|
def test_errors(self):
|
95
98
|
# Provided an invalid value for hammer_type
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|