sgf-parser 0.0.3__tar.gz → 0.0.5__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.
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/PKG-INFO +5 -11
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/pyproject.toml +15 -12
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method.py +1 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_dp.py +6 -6
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_wst.py +3 -2
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/types.py +6 -6
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/parser.py +1 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/LICENSE +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/README.md +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/__init__.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/datetime_parser.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/__init__.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_cpt.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_dt.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_rp.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_slb.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_srs.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_sti.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_svt.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_tot.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_tr.py +0 -0
- {sgf_parser-0.0.3 → sgf_parser-0.0.5}/src/sgf_parser/models/method_type.py +0 -0
|
@@ -1,26 +1,20 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: sgf-parser
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.5
|
|
4
4
|
Summary: Parser for the Swedish Geotechnical Society / Svenska Geotekniska Föreningen (SGF) data format
|
|
5
|
-
License: MIT
|
|
6
5
|
Author: Jostein Leira
|
|
7
6
|
Author-email: jostein@leira.net
|
|
8
7
|
Maintainer: Jostein Leira
|
|
9
8
|
Maintainer-email: jostein@leira.net
|
|
10
9
|
Requires-Python: >=3.11,<4
|
|
11
10
|
Classifier: Development Status :: 5 - Production/Stable
|
|
12
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
13
11
|
Classifier: Operating System :: OS Independent
|
|
14
12
|
Classifier: Programming Language :: Python :: 3
|
|
15
|
-
Classifier: Programming Language :: Python :: 3.11
|
|
16
|
-
Classifier: Programming Language :: Python :: 3.12
|
|
17
|
-
Classifier: Programming Language :: Python :: 3.13
|
|
18
13
|
Classifier: Topic :: Scientific/Engineering :: GIS
|
|
19
|
-
|
|
20
|
-
Requires-Dist:
|
|
21
|
-
Requires-Dist:
|
|
22
|
-
|
|
23
|
-
Project-URL: Repository, https://github.com/norwegian-geotechnical-institute/sgf-parser
|
|
14
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
15
|
+
Requires-Dist: pydantic (>=2.10)
|
|
16
|
+
Requires-Dist: python-dateutil (>=2.9.0.post0)
|
|
17
|
+
Requires-Dist: types-python-dateutil (>=2.9)
|
|
24
18
|
Description-Content-Type: text/markdown
|
|
25
19
|
|
|
26
20
|
# sgf-parser
|
|
@@ -13,23 +13,31 @@ exclude = '''
|
|
|
13
13
|
)/
|
|
14
14
|
'''
|
|
15
15
|
|
|
16
|
-
[
|
|
16
|
+
[project]
|
|
17
17
|
name = "sgf-parser"
|
|
18
|
-
version = "0.0.
|
|
18
|
+
version = "0.0.5"
|
|
19
19
|
description = "Parser for the Swedish Geotechnical Society / Svenska Geotekniska Föreningen (SGF) data format"
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
authors = [
|
|
21
|
+
{ name = "Jostein Leira", email = "jostein@leira.net" }
|
|
22
|
+
]
|
|
23
|
+
maintainers = [
|
|
24
|
+
{ name = "Jostein Leira", email = "jostein@leira.net" }
|
|
25
|
+
]
|
|
23
26
|
readme = "README.md"
|
|
24
27
|
homepage = "https://github.com/norwegian-geotechnical-institute/sgf-parser"
|
|
25
28
|
repository = "https://github.com/norwegian-geotechnical-institute/sgf-parser"
|
|
26
29
|
classifiers = [
|
|
27
30
|
"Development Status :: 5 - Production/Stable",
|
|
28
|
-
# "Development Status :: 4 - Beta",
|
|
29
|
-
# "Development Status :: 3 - Alpha",
|
|
30
31
|
"Operating System :: OS Independent",
|
|
31
32
|
"Programming Language :: Python :: 3",
|
|
32
33
|
"Topic :: Scientific/Engineering :: GIS",
|
|
34
|
+
"License :: OSI Approved :: MIT License",
|
|
35
|
+
]
|
|
36
|
+
requires-python = ">=3.11,<4"
|
|
37
|
+
dependencies=[
|
|
38
|
+
"pydantic>=2.10",
|
|
39
|
+
"python-dateutil>=2.9.0.post0",
|
|
40
|
+
"types-python-dateutil>=2.9"
|
|
33
41
|
]
|
|
34
42
|
packages = [
|
|
35
43
|
{ include = "sgf_parser", from="src" },
|
|
@@ -56,11 +64,6 @@ check_untyped_defs = true
|
|
|
56
64
|
no_implicit_reexport = false
|
|
57
65
|
|
|
58
66
|
|
|
59
|
-
[tool.poetry.dependencies]
|
|
60
|
-
python = ">=3.11,<4"
|
|
61
|
-
pydantic = "^2.10"
|
|
62
|
-
python-dateutil = "^2.9.0.post0"
|
|
63
|
-
types-python-dateutil = "^2.9"
|
|
64
67
|
|
|
65
68
|
|
|
66
69
|
[tool.poetry.group.dev.dependencies]
|
|
@@ -422,6 +422,7 @@ class Method(BaseModel):
|
|
|
422
422
|
|
|
423
423
|
location_name: str | None = Field(None, alias="KP")
|
|
424
424
|
project_number: str | None = Field(None, alias="HJ")
|
|
425
|
+
borehole_name: str | None = Field(None, alias="HK", description="Investigation point/Borehole name")
|
|
425
426
|
method_type_string: str | None = Field(None, alias="HM")
|
|
426
427
|
|
|
427
428
|
# HX, HY, HZ
|
|
@@ -51,7 +51,7 @@ class MethodDP(Method):
|
|
|
51
51
|
method_type: Literal[MethodType.DP] = MethodType.DP
|
|
52
52
|
method_data_type: type[MethodDPData] = MethodDPData
|
|
53
53
|
|
|
54
|
-
|
|
54
|
+
dynamic_probing_type: DPType
|
|
55
55
|
|
|
56
56
|
predrilling_depth: Decimal = Field(Decimal("0"), alias="HO")
|
|
57
57
|
|
|
@@ -68,14 +68,14 @@ class MethodDP(Method):
|
|
|
68
68
|
def set_operation(cls, data: Any) -> Any:
|
|
69
69
|
if isinstance(data, dict):
|
|
70
70
|
if "HM" in data and data["HM"] is not None:
|
|
71
|
-
data["
|
|
72
|
-
"8": DPType.
|
|
73
|
-
"108A": DPType.
|
|
71
|
+
data["dynamic_probing_type"] = {
|
|
72
|
+
"8": DPType.DPSHA,
|
|
73
|
+
"108A": DPType.DPSHA,
|
|
74
74
|
"108B": DPType.DPL,
|
|
75
75
|
"108C": DPType.DPM,
|
|
76
76
|
"108D": DPType.DPH,
|
|
77
|
-
"9": DPType.
|
|
78
|
-
"108E": DPType.
|
|
77
|
+
"9": DPType.DPSHB,
|
|
78
|
+
"108E": DPType.DPSHB,
|
|
79
79
|
}[data["HM"]]
|
|
80
80
|
|
|
81
81
|
return data
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
from decimal import Decimal
|
|
2
2
|
from typing import Literal, Any
|
|
3
3
|
|
|
4
|
-
from pydantic import Field, model_validator
|
|
4
|
+
from pydantic import Field, model_validator, AliasChoices
|
|
5
5
|
|
|
6
6
|
from sgf_parser.models import MethodData, Method, MethodType
|
|
7
7
|
from sgf_parser.models.types import Operation
|
|
@@ -17,7 +17,7 @@ class MethodWSTData(MethodData):
|
|
|
17
17
|
|
|
18
18
|
depth: Decimal = Field(..., alias="D", description="Depth (m)")
|
|
19
19
|
turning: Decimal = Field(..., alias="H", description="Turning (half revolution/0.2 m)")
|
|
20
|
-
load: Decimal = Field(
|
|
20
|
+
load: Decimal | None = Field(None, description="Load (kN)", validation_alias=AliasChoices("W", "A"))
|
|
21
21
|
penetration_rate: Decimal | None = Field(None, alias="B", description="Penetration rate (mm/s)")
|
|
22
22
|
|
|
23
23
|
hammering: bool | None = Field(None, alias="AP")
|
|
@@ -47,6 +47,7 @@ class MethodWST(Method):
|
|
|
47
47
|
if "HM" in data and data["HM"] is not None:
|
|
48
48
|
data["operation"] = {
|
|
49
49
|
"101": Operation.MANUAL,
|
|
50
|
+
"2": Operation.MECHANICAL,
|
|
50
51
|
"102": Operation.MECHANICAL,
|
|
51
52
|
}[data["HM"]]
|
|
52
53
|
|
|
@@ -121,10 +121,10 @@ class SoundingClass(enum.StrEnum):
|
|
|
121
121
|
)
|
|
122
122
|
"""
|
|
123
123
|
|
|
124
|
-
JB1 = "
|
|
125
|
-
JB2 = "
|
|
126
|
-
JB3 = "
|
|
127
|
-
JBTOT = "
|
|
124
|
+
JB1 = "JB1"
|
|
125
|
+
JB2 = "JB2"
|
|
126
|
+
JB3 = "JB3"
|
|
127
|
+
JBTOT = "JBTOT"
|
|
128
128
|
|
|
129
129
|
|
|
130
130
|
class Operation(enum.StrEnum):
|
|
@@ -142,8 +142,8 @@ class DPType(enum.StrEnum):
|
|
|
142
142
|
|
|
143
143
|
"""
|
|
144
144
|
|
|
145
|
-
|
|
145
|
+
DPSHA = "DPSHA"
|
|
146
146
|
DPL = "DPL"
|
|
147
147
|
DPM = "DPM"
|
|
148
148
|
DPH = "DPH"
|
|
149
|
-
|
|
149
|
+
DPSHB = "DPSHB"
|
|
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
|