osis-python 0.4.4__tar.gz → 0.5.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.
- {osis_python-0.4.4/src/osis_python.egg-info → osis_python-0.5.0}/PKG-INFO +18 -26
- {osis_python-0.4.4 → osis_python-0.5.0}/README.md +17 -25
- {osis_python-0.4.4 → osis_python-0.5.0/src/osis_python.egg-info}/PKG-INFO +18 -26
- {osis_python-0.4.4 → osis_python-0.5.0}/src/osis_python.egg-info/SOURCES.txt +9 -2
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/__init__.py +1 -1
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/boundary/manager.py +161 -125
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/control/manager.py +17 -17
- osis_python-0.5.0/src/pyosis/core/apdl_sync.py +155 -0
- osis_python-0.5.0/src/pyosis/core/basic_manager.py +19 -0
- osis_python-0.5.0/src/pyosis/core/build.py +2267 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/core/client.py +2 -1
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/core/engine.py +64 -42
- osis_python-0.5.0/src/pyosis/core/sync_apdl_cli.py +49 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/dynamic/manager.py +279 -115
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/element/interface.py +5 -5
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/element/manager.py +136 -78
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/geometry/manager.py +42 -5
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/live/analysis.py +4 -4
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/live/manager.py +273 -94
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/load/manager.py +492 -281
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/material/manager.py +91 -55
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/node/manager.py +17 -10
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/post/manager.py +4 -4
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/property/component_thickness.py +2 -2
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/property/manager.py +339 -19
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/common.py +14 -13
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/composite.py +15 -3
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/manager.py +1412 -1156
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/numeric.py +1 -1
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/settlement/interface.py +3 -3
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/settlement/manager.py +25 -9
- osis_python-0.5.0/src/pyosis/stability/__init__.py +2 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/stability/manager.py +78 -78
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/stage/manager.py +61 -51
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/thickness/manager.py +56 -1
- osis_python-0.5.0/src/pyosis/transfer/__init__.py +22 -0
- osis_python-0.5.0/src/pyosis/transfer/generator.py +116 -0
- osis_python-0.5.0/src/pyosis/transfer/matrix.py +107 -0
- osis_python-0.5.0/src/pyosis/transfer/parser.py +216 -0
- osis_python-0.5.0/src/pyosis/transfer/routes.py +184 -0
- osis_python-0.5.0/src/pyosis/transfer/split.py +44 -0
- osis_python-0.5.0/src/pyosis/transfer/sync_exec.py +256 -0
- osis_python-0.4.4/src/pyosis/stability/__init__.py +0 -2
- osis_python-0.4.4/src/pyosis/transfer/__init__.py +0 -50
- osis_python-0.4.4/src/pyosis/transfer/command_map.py +0 -695
- osis_python-0.4.4/src/pyosis/transfer/generator.py +0 -366
- osis_python-0.4.4/src/pyosis/transfer/parser.py +0 -150
- {osis_python-0.4.4 → osis_python-0.5.0}/LICENSE +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/pyproject.toml +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/setup.cfg +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/osis_python.egg-info/dependency_links.txt +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/osis_python.egg-info/requires.txt +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/osis_python.egg-info/top_level.txt +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/boundary/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/boundary/interface.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/control/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/control/control.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/control/io.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/control/nonlinear.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/core/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/core/all_func.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/core/command.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/dynamic/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/dynamic/load_to_mass.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/dynamic/modal.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/dynamic/seismic.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/element/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/general/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/general/interface.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/geometry/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/geometry/interface.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/live/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/live/grade.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/live/lane.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/load/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/load/loadcase.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/load/static.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/load/tendon.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/material/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/material/interface.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/node/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/node/interface.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/post/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/post/combine.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/post/design_check.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/post/display.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/project/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/project/interface.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/project/manager.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/property/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/property/coordinate.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/property/creep_shrink.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/property/damping.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/property/pu_curve.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/quick_building/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/quick_building/interface.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/result/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/result/check.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/result/env.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/result/loadcase.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/result/manager.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/result/result.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/param.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/rebar.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/rib.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/section/steel.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/settlement/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/stability/buckling.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/stage/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/stage/define.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/stage/overall.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/thickness/__init__.py +0 -0
- {osis_python-0.4.4 → osis_python-0.5.0}/src/pyosis/thickness/interface.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: osis-python
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.5.0
|
|
4
4
|
Summary: A Python client library for Osis APDL
|
|
5
5
|
Author-email: "CCCC Highway Consultant Co. Ltd." <support@osisbim.com>
|
|
6
6
|
License-Expression: MIT
|
|
@@ -76,10 +76,10 @@ engine.control.set_calc_tendon(True)
|
|
|
76
76
|
engine.control.set_calc_creep(True)
|
|
77
77
|
|
|
78
78
|
# Create sections
|
|
79
|
-
sec = engine.section.create_circle("
|
|
79
|
+
sec = engine.section.create_circle("CircleSection", d=0.5, tw=0.02)
|
|
80
80
|
|
|
81
81
|
# Create materials
|
|
82
|
-
mat = engine.material.create_conc("
|
|
82
|
+
mat = engine.material.create_conc("C30Concrete", eCode="JTG3362_2018", eGrade="C30")
|
|
83
83
|
|
|
84
84
|
# Create nodes
|
|
85
85
|
n1 = engine.node.create(0, 0, 0)
|
|
@@ -172,11 +172,11 @@ Some managers contain sub-managers, accessed via attributes:
|
|
|
172
172
|
|
|
173
173
|
```python
|
|
174
174
|
# Element groups
|
|
175
|
-
grp = engine.element.group.create("
|
|
175
|
+
grp = engine.element.group.create("MainGirderElements")
|
|
176
176
|
grp.add([1, 2, 3])
|
|
177
177
|
|
|
178
178
|
# Boundary groups
|
|
179
|
-
bg = engine.boundary.group.create("
|
|
179
|
+
bg = engine.boundary.group.create("AbutmentBoundaries")
|
|
180
180
|
bg.add([1, 2])
|
|
181
181
|
|
|
182
182
|
# Various boundary types
|
|
@@ -195,13 +195,13 @@ prop = engine.tendon.prop.create_in(
|
|
|
195
195
|
)
|
|
196
196
|
shape = engine.tendon.shape.create_arc3d(
|
|
197
197
|
"N1", n_num=2, prop="15-10",
|
|
198
|
-
element_group="
|
|
198
|
+
element_group="MainGirderElements", curve_name="curve1"
|
|
199
199
|
)
|
|
200
200
|
|
|
201
201
|
# Live loads
|
|
202
|
-
grade = engine.live.grade.create("
|
|
203
|
-
lane = engine.live.lane.create("
|
|
204
|
-
case = engine.live.case.create("
|
|
202
|
+
grade = engine.live.grade.create("HighwayClassI")
|
|
203
|
+
lane = engine.live.lane.create("Lane1")
|
|
204
|
+
case = engine.live.case.create("LiveLoadCase 1")
|
|
205
205
|
```
|
|
206
206
|
|
|
207
207
|
### Property & Thickness Management
|
|
@@ -264,10 +264,10 @@ Some `create_*` functions support explicit numbering via the `no` parameter. If
|
|
|
264
264
|
|
|
265
265
|
```python
|
|
266
266
|
# Auto-assigned number
|
|
267
|
-
sec = engine.section.create_circle("
|
|
267
|
+
sec = engine.section.create_circle("Section1", d=0.5)
|
|
268
268
|
|
|
269
269
|
# Explicit number
|
|
270
|
-
sec = engine.section.create_circle("
|
|
270
|
+
sec = engine.section.create_circle("Section1", d=0.5, no=100)
|
|
271
271
|
```
|
|
272
272
|
|
|
273
273
|
## Result Export
|
|
@@ -279,11 +279,11 @@ After solving, you can export various analysis results using `engine.result`. Al
|
|
|
279
279
|
df = engine.result.loadcase("Self-weight", "LCEF")
|
|
280
280
|
|
|
281
281
|
# Export envelope results (element forces)
|
|
282
|
-
df = engine.result.env("
|
|
282
|
+
df = engine.result.env("BasicCombinationEnvelope", "EnvEF")
|
|
283
283
|
|
|
284
284
|
# Export design check results
|
|
285
285
|
df = engine.result.check(
|
|
286
|
-
"混凝土", "正截面抗弯验算", "
|
|
286
|
+
"混凝土", "正截面抗弯验算", "基本组合"
|
|
287
287
|
)
|
|
288
288
|
|
|
289
289
|
# Batch export all check results from Check folder
|
|
@@ -296,7 +296,7 @@ Supported result types:
|
|
|
296
296
|
- **Load case**: `LCEF` (element force), `LCED` (element displacement), `LCND` (node displacement), `LCBF` (boundary reaction), `LCTL` (tendon loss), `LCS` (element stress)
|
|
297
297
|
- **Envelope**: `EnvBF` (boundary reaction), `EnvEF` (element force), `EnvES` (element strain), `EnvS` (element stress), `EnvND` (node displacement)
|
|
298
298
|
|
|
299
|
-
Requires `pandas` to be installed: `
|
|
299
|
+
Requires `pandas` to be installed: `python -m install pandas`
|
|
300
300
|
|
|
301
301
|
## Complete Example
|
|
302
302
|
|
|
@@ -319,12 +319,12 @@ engine.control.set_inc_tendon(True)
|
|
|
319
319
|
engine.control.set_nonlinear(geom=False, link=False)
|
|
320
320
|
|
|
321
321
|
# Sections
|
|
322
|
-
engine.section.create_circle("
|
|
323
|
-
engine.section.create_circle("
|
|
322
|
+
engine.section.create_circle("CircleSection1", d=0.219, tw=0.012, no=1)
|
|
323
|
+
engine.section.create_circle("CircleSection2", d=0.180, tw=0.008, no=2)
|
|
324
324
|
|
|
325
325
|
# Materials
|
|
326
326
|
engine.material.create_steel(
|
|
327
|
-
"
|
|
327
|
+
"Steel1", eCode="JTGD64_2015", eGrade="Q345", dDmp=0.05, no=1
|
|
328
328
|
)
|
|
329
329
|
|
|
330
330
|
# Nodes
|
|
@@ -343,7 +343,7 @@ engine.boundary.get(1).assign("a", [1, 2])
|
|
|
343
343
|
|
|
344
344
|
# Loads
|
|
345
345
|
lc = engine.load.create(
|
|
346
|
-
"
|
|
346
|
+
"CustomLoadCase1",
|
|
347
347
|
load_case_type="USER",
|
|
348
348
|
prompt="Two forces applied at nodes 3 and 4"
|
|
349
349
|
)
|
|
@@ -354,14 +354,6 @@ lc.create_nforce(4, dFx=200000, dFy=0, dFz=0)
|
|
|
354
354
|
engine.solve()
|
|
355
355
|
```
|
|
356
356
|
|
|
357
|
-
## Important Notes
|
|
358
|
-
|
|
359
|
-
1. **OSIS must be running**: Before executing code, ensure the OSIS software is launched and logged in. pyosis communicates with OSIS via HTTP.
|
|
360
|
-
2. **Exception handling**: All operations throw `RuntimeError` on failure. It is recommended to add exception handling in production code.
|
|
361
|
-
3. **Stateless design**: Managers do not cache data. Every query method (`all()`, `get()`, `filter()`) fetches fresh data from OSIS via HTTP. This ensures consistency but incurs network overhead. Cache results locally when iterating in loops.
|
|
362
|
-
4. **Number uniqueness**: When explicitly specifying `no`, if the number already exists, the behavior depends on the OSIS underlying implementation (usually overwrites or raises an error).
|
|
363
|
-
|
|
364
357
|
## More Resources
|
|
365
358
|
|
|
366
359
|
- [tests/](tests/): Example code for each module
|
|
367
|
-
- [templetes/](templetes/): Complete bridge modeling template projects
|
|
@@ -45,10 +45,10 @@ engine.control.set_calc_tendon(True)
|
|
|
45
45
|
engine.control.set_calc_creep(True)
|
|
46
46
|
|
|
47
47
|
# Create sections
|
|
48
|
-
sec = engine.section.create_circle("
|
|
48
|
+
sec = engine.section.create_circle("CircleSection", d=0.5, tw=0.02)
|
|
49
49
|
|
|
50
50
|
# Create materials
|
|
51
|
-
mat = engine.material.create_conc("
|
|
51
|
+
mat = engine.material.create_conc("C30Concrete", eCode="JTG3362_2018", eGrade="C30")
|
|
52
52
|
|
|
53
53
|
# Create nodes
|
|
54
54
|
n1 = engine.node.create(0, 0, 0)
|
|
@@ -141,11 +141,11 @@ Some managers contain sub-managers, accessed via attributes:
|
|
|
141
141
|
|
|
142
142
|
```python
|
|
143
143
|
# Element groups
|
|
144
|
-
grp = engine.element.group.create("
|
|
144
|
+
grp = engine.element.group.create("MainGirderElements")
|
|
145
145
|
grp.add([1, 2, 3])
|
|
146
146
|
|
|
147
147
|
# Boundary groups
|
|
148
|
-
bg = engine.boundary.group.create("
|
|
148
|
+
bg = engine.boundary.group.create("AbutmentBoundaries")
|
|
149
149
|
bg.add([1, 2])
|
|
150
150
|
|
|
151
151
|
# Various boundary types
|
|
@@ -164,13 +164,13 @@ prop = engine.tendon.prop.create_in(
|
|
|
164
164
|
)
|
|
165
165
|
shape = engine.tendon.shape.create_arc3d(
|
|
166
166
|
"N1", n_num=2, prop="15-10",
|
|
167
|
-
element_group="
|
|
167
|
+
element_group="MainGirderElements", curve_name="curve1"
|
|
168
168
|
)
|
|
169
169
|
|
|
170
170
|
# Live loads
|
|
171
|
-
grade = engine.live.grade.create("
|
|
172
|
-
lane = engine.live.lane.create("
|
|
173
|
-
case = engine.live.case.create("
|
|
171
|
+
grade = engine.live.grade.create("HighwayClassI")
|
|
172
|
+
lane = engine.live.lane.create("Lane1")
|
|
173
|
+
case = engine.live.case.create("LiveLoadCase 1")
|
|
174
174
|
```
|
|
175
175
|
|
|
176
176
|
### Property & Thickness Management
|
|
@@ -233,10 +233,10 @@ Some `create_*` functions support explicit numbering via the `no` parameter. If
|
|
|
233
233
|
|
|
234
234
|
```python
|
|
235
235
|
# Auto-assigned number
|
|
236
|
-
sec = engine.section.create_circle("
|
|
236
|
+
sec = engine.section.create_circle("Section1", d=0.5)
|
|
237
237
|
|
|
238
238
|
# Explicit number
|
|
239
|
-
sec = engine.section.create_circle("
|
|
239
|
+
sec = engine.section.create_circle("Section1", d=0.5, no=100)
|
|
240
240
|
```
|
|
241
241
|
|
|
242
242
|
## Result Export
|
|
@@ -248,11 +248,11 @@ After solving, you can export various analysis results using `engine.result`. Al
|
|
|
248
248
|
df = engine.result.loadcase("Self-weight", "LCEF")
|
|
249
249
|
|
|
250
250
|
# Export envelope results (element forces)
|
|
251
|
-
df = engine.result.env("
|
|
251
|
+
df = engine.result.env("BasicCombinationEnvelope", "EnvEF")
|
|
252
252
|
|
|
253
253
|
# Export design check results
|
|
254
254
|
df = engine.result.check(
|
|
255
|
-
"混凝土", "正截面抗弯验算", "
|
|
255
|
+
"混凝土", "正截面抗弯验算", "基本组合"
|
|
256
256
|
)
|
|
257
257
|
|
|
258
258
|
# Batch export all check results from Check folder
|
|
@@ -265,7 +265,7 @@ Supported result types:
|
|
|
265
265
|
- **Load case**: `LCEF` (element force), `LCED` (element displacement), `LCND` (node displacement), `LCBF` (boundary reaction), `LCTL` (tendon loss), `LCS` (element stress)
|
|
266
266
|
- **Envelope**: `EnvBF` (boundary reaction), `EnvEF` (element force), `EnvES` (element strain), `EnvS` (element stress), `EnvND` (node displacement)
|
|
267
267
|
|
|
268
|
-
Requires `pandas` to be installed: `
|
|
268
|
+
Requires `pandas` to be installed: `python -m install pandas`
|
|
269
269
|
|
|
270
270
|
## Complete Example
|
|
271
271
|
|
|
@@ -288,12 +288,12 @@ engine.control.set_inc_tendon(True)
|
|
|
288
288
|
engine.control.set_nonlinear(geom=False, link=False)
|
|
289
289
|
|
|
290
290
|
# Sections
|
|
291
|
-
engine.section.create_circle("
|
|
292
|
-
engine.section.create_circle("
|
|
291
|
+
engine.section.create_circle("CircleSection1", d=0.219, tw=0.012, no=1)
|
|
292
|
+
engine.section.create_circle("CircleSection2", d=0.180, tw=0.008, no=2)
|
|
293
293
|
|
|
294
294
|
# Materials
|
|
295
295
|
engine.material.create_steel(
|
|
296
|
-
"
|
|
296
|
+
"Steel1", eCode="JTGD64_2015", eGrade="Q345", dDmp=0.05, no=1
|
|
297
297
|
)
|
|
298
298
|
|
|
299
299
|
# Nodes
|
|
@@ -312,7 +312,7 @@ engine.boundary.get(1).assign("a", [1, 2])
|
|
|
312
312
|
|
|
313
313
|
# Loads
|
|
314
314
|
lc = engine.load.create(
|
|
315
|
-
"
|
|
315
|
+
"CustomLoadCase1",
|
|
316
316
|
load_case_type="USER",
|
|
317
317
|
prompt="Two forces applied at nodes 3 and 4"
|
|
318
318
|
)
|
|
@@ -323,14 +323,6 @@ lc.create_nforce(4, dFx=200000, dFy=0, dFz=0)
|
|
|
323
323
|
engine.solve()
|
|
324
324
|
```
|
|
325
325
|
|
|
326
|
-
## Important Notes
|
|
327
|
-
|
|
328
|
-
1. **OSIS must be running**: Before executing code, ensure the OSIS software is launched and logged in. pyosis communicates with OSIS via HTTP.
|
|
329
|
-
2. **Exception handling**: All operations throw `RuntimeError` on failure. It is recommended to add exception handling in production code.
|
|
330
|
-
3. **Stateless design**: Managers do not cache data. Every query method (`all()`, `get()`, `filter()`) fetches fresh data from OSIS via HTTP. This ensures consistency but incurs network overhead. Cache results locally when iterating in loops.
|
|
331
|
-
4. **Number uniqueness**: When explicitly specifying `no`, if the number already exists, the behavior depends on the OSIS underlying implementation (usually overwrites or raises an error).
|
|
332
|
-
|
|
333
326
|
## More Resources
|
|
334
327
|
|
|
335
328
|
- [tests/](tests/): Example code for each module
|
|
336
|
-
- [templetes/](templetes/): Complete bridge modeling template projects
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: osis-python
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.5.0
|
|
4
4
|
Summary: A Python client library for Osis APDL
|
|
5
5
|
Author-email: "CCCC Highway Consultant Co. Ltd." <support@osisbim.com>
|
|
6
6
|
License-Expression: MIT
|
|
@@ -76,10 +76,10 @@ engine.control.set_calc_tendon(True)
|
|
|
76
76
|
engine.control.set_calc_creep(True)
|
|
77
77
|
|
|
78
78
|
# Create sections
|
|
79
|
-
sec = engine.section.create_circle("
|
|
79
|
+
sec = engine.section.create_circle("CircleSection", d=0.5, tw=0.02)
|
|
80
80
|
|
|
81
81
|
# Create materials
|
|
82
|
-
mat = engine.material.create_conc("
|
|
82
|
+
mat = engine.material.create_conc("C30Concrete", eCode="JTG3362_2018", eGrade="C30")
|
|
83
83
|
|
|
84
84
|
# Create nodes
|
|
85
85
|
n1 = engine.node.create(0, 0, 0)
|
|
@@ -172,11 +172,11 @@ Some managers contain sub-managers, accessed via attributes:
|
|
|
172
172
|
|
|
173
173
|
```python
|
|
174
174
|
# Element groups
|
|
175
|
-
grp = engine.element.group.create("
|
|
175
|
+
grp = engine.element.group.create("MainGirderElements")
|
|
176
176
|
grp.add([1, 2, 3])
|
|
177
177
|
|
|
178
178
|
# Boundary groups
|
|
179
|
-
bg = engine.boundary.group.create("
|
|
179
|
+
bg = engine.boundary.group.create("AbutmentBoundaries")
|
|
180
180
|
bg.add([1, 2])
|
|
181
181
|
|
|
182
182
|
# Various boundary types
|
|
@@ -195,13 +195,13 @@ prop = engine.tendon.prop.create_in(
|
|
|
195
195
|
)
|
|
196
196
|
shape = engine.tendon.shape.create_arc3d(
|
|
197
197
|
"N1", n_num=2, prop="15-10",
|
|
198
|
-
element_group="
|
|
198
|
+
element_group="MainGirderElements", curve_name="curve1"
|
|
199
199
|
)
|
|
200
200
|
|
|
201
201
|
# Live loads
|
|
202
|
-
grade = engine.live.grade.create("
|
|
203
|
-
lane = engine.live.lane.create("
|
|
204
|
-
case = engine.live.case.create("
|
|
202
|
+
grade = engine.live.grade.create("HighwayClassI")
|
|
203
|
+
lane = engine.live.lane.create("Lane1")
|
|
204
|
+
case = engine.live.case.create("LiveLoadCase 1")
|
|
205
205
|
```
|
|
206
206
|
|
|
207
207
|
### Property & Thickness Management
|
|
@@ -264,10 +264,10 @@ Some `create_*` functions support explicit numbering via the `no` parameter. If
|
|
|
264
264
|
|
|
265
265
|
```python
|
|
266
266
|
# Auto-assigned number
|
|
267
|
-
sec = engine.section.create_circle("
|
|
267
|
+
sec = engine.section.create_circle("Section1", d=0.5)
|
|
268
268
|
|
|
269
269
|
# Explicit number
|
|
270
|
-
sec = engine.section.create_circle("
|
|
270
|
+
sec = engine.section.create_circle("Section1", d=0.5, no=100)
|
|
271
271
|
```
|
|
272
272
|
|
|
273
273
|
## Result Export
|
|
@@ -279,11 +279,11 @@ After solving, you can export various analysis results using `engine.result`. Al
|
|
|
279
279
|
df = engine.result.loadcase("Self-weight", "LCEF")
|
|
280
280
|
|
|
281
281
|
# Export envelope results (element forces)
|
|
282
|
-
df = engine.result.env("
|
|
282
|
+
df = engine.result.env("BasicCombinationEnvelope", "EnvEF")
|
|
283
283
|
|
|
284
284
|
# Export design check results
|
|
285
285
|
df = engine.result.check(
|
|
286
|
-
"混凝土", "正截面抗弯验算", "
|
|
286
|
+
"混凝土", "正截面抗弯验算", "基本组合"
|
|
287
287
|
)
|
|
288
288
|
|
|
289
289
|
# Batch export all check results from Check folder
|
|
@@ -296,7 +296,7 @@ Supported result types:
|
|
|
296
296
|
- **Load case**: `LCEF` (element force), `LCED` (element displacement), `LCND` (node displacement), `LCBF` (boundary reaction), `LCTL` (tendon loss), `LCS` (element stress)
|
|
297
297
|
- **Envelope**: `EnvBF` (boundary reaction), `EnvEF` (element force), `EnvES` (element strain), `EnvS` (element stress), `EnvND` (node displacement)
|
|
298
298
|
|
|
299
|
-
Requires `pandas` to be installed: `
|
|
299
|
+
Requires `pandas` to be installed: `python -m install pandas`
|
|
300
300
|
|
|
301
301
|
## Complete Example
|
|
302
302
|
|
|
@@ -319,12 +319,12 @@ engine.control.set_inc_tendon(True)
|
|
|
319
319
|
engine.control.set_nonlinear(geom=False, link=False)
|
|
320
320
|
|
|
321
321
|
# Sections
|
|
322
|
-
engine.section.create_circle("
|
|
323
|
-
engine.section.create_circle("
|
|
322
|
+
engine.section.create_circle("CircleSection1", d=0.219, tw=0.012, no=1)
|
|
323
|
+
engine.section.create_circle("CircleSection2", d=0.180, tw=0.008, no=2)
|
|
324
324
|
|
|
325
325
|
# Materials
|
|
326
326
|
engine.material.create_steel(
|
|
327
|
-
"
|
|
327
|
+
"Steel1", eCode="JTGD64_2015", eGrade="Q345", dDmp=0.05, no=1
|
|
328
328
|
)
|
|
329
329
|
|
|
330
330
|
# Nodes
|
|
@@ -343,7 +343,7 @@ engine.boundary.get(1).assign("a", [1, 2])
|
|
|
343
343
|
|
|
344
344
|
# Loads
|
|
345
345
|
lc = engine.load.create(
|
|
346
|
-
"
|
|
346
|
+
"CustomLoadCase1",
|
|
347
347
|
load_case_type="USER",
|
|
348
348
|
prompt="Two forces applied at nodes 3 and 4"
|
|
349
349
|
)
|
|
@@ -354,14 +354,6 @@ lc.create_nforce(4, dFx=200000, dFy=0, dFz=0)
|
|
|
354
354
|
engine.solve()
|
|
355
355
|
```
|
|
356
356
|
|
|
357
|
-
## Important Notes
|
|
358
|
-
|
|
359
|
-
1. **OSIS must be running**: Before executing code, ensure the OSIS software is launched and logged in. pyosis communicates with OSIS via HTTP.
|
|
360
|
-
2. **Exception handling**: All operations throw `RuntimeError` on failure. It is recommended to add exception handling in production code.
|
|
361
|
-
3. **Stateless design**: Managers do not cache data. Every query method (`all()`, `get()`, `filter()`) fetches fresh data from OSIS via HTTP. This ensures consistency but incurs network overhead. Cache results locally when iterating in loops.
|
|
362
|
-
4. **Number uniqueness**: When explicitly specifying `no`, if the number already exists, the behavior depends on the OSIS underlying implementation (usually overwrites or raises an error).
|
|
363
|
-
|
|
364
357
|
## More Resources
|
|
365
358
|
|
|
366
359
|
- [tests/](tests/): Example code for each module
|
|
367
|
-
- [templetes/](templetes/): Complete bridge modeling template projects
|
|
@@ -17,9 +17,13 @@ src/pyosis/control/manager.py
|
|
|
17
17
|
src/pyosis/control/nonlinear.py
|
|
18
18
|
src/pyosis/core/__init__.py
|
|
19
19
|
src/pyosis/core/all_func.py
|
|
20
|
+
src/pyosis/core/apdl_sync.py
|
|
21
|
+
src/pyosis/core/basic_manager.py
|
|
22
|
+
src/pyosis/core/build.py
|
|
20
23
|
src/pyosis/core/client.py
|
|
21
24
|
src/pyosis/core/command.py
|
|
22
25
|
src/pyosis/core/engine.py
|
|
26
|
+
src/pyosis/core/sync_apdl_cli.py
|
|
23
27
|
src/pyosis/dynamic/__init__.py
|
|
24
28
|
src/pyosis/dynamic/load_to_mass.py
|
|
25
29
|
src/pyosis/dynamic/manager.py
|
|
@@ -95,6 +99,9 @@ src/pyosis/thickness/__init__.py
|
|
|
95
99
|
src/pyosis/thickness/interface.py
|
|
96
100
|
src/pyosis/thickness/manager.py
|
|
97
101
|
src/pyosis/transfer/__init__.py
|
|
98
|
-
src/pyosis/transfer/command_map.py
|
|
99
102
|
src/pyosis/transfer/generator.py
|
|
100
|
-
src/pyosis/transfer/
|
|
103
|
+
src/pyosis/transfer/matrix.py
|
|
104
|
+
src/pyosis/transfer/parser.py
|
|
105
|
+
src/pyosis/transfer/routes.py
|
|
106
|
+
src/pyosis/transfer/split.py
|
|
107
|
+
src/pyosis/transfer/sync_exec.py
|
|
@@ -7,7 +7,7 @@ A library for extending OSIS functionality.
|
|
|
7
7
|
A library that allows users to use CAE with great flexibility.
|
|
8
8
|
"""
|
|
9
9
|
|
|
10
|
-
__version__ = "0.
|
|
10
|
+
__version__ = "0.5.0"
|
|
11
11
|
__author__ = "CCCC Highway Consultant Co. Ltd." # 中交公路规划设计院 - 工程技术研究中心 - lzh - wjh - myf
|
|
12
12
|
|
|
13
13
|
from .core.engine import OSISEngine
|