Skip to content
Merged
Show file tree
Hide file tree
Changes from 23 commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
0821fa3
initial progress (flow360)
alexxu-flex Nov 7, 2025
56b258b
progress
alexxu-flex Nov 7, 2025
40fb0c0
json parsing mostly done, w/ test
alexxu-flex Nov 10, 2025
1182376
changes in pipeline to allow wind tunnel farfield
alexxu-flex Nov 11, 2025
c4aaf44
formatted
alexxu-flex Nov 11, 2025
eec11e5
fix linting
alexxu-flex Nov 12, 2025
7aa8d39
Merge branch 'main' into alexxu/windtunnel-flow360
alexxu-flex Nov 12, 2025
9300c4c
Merge branch 'main' into alexxu/windtunnel-flow360
alexxu-flex Nov 12, 2025
8d1bc57
Merge branch 'main' into alexxu/windtunnel-flow360
alexxu-flex Nov 12, 2025
b3fb803
black issue caused by merge conflict
alexxu-flex Nov 12, 2025
15d99be
Merge branch 'main' into alexxu/windtunnel-flow360
alexxu-flex Nov 12, 2025
cf3b392
merged branch main
alexxu-flex Nov 13, 2025
e98dddd
added floor type defaults, pd.Field descriptions
alexxu-flex Nov 14, 2025
f34bfea
Merge branch 'main' into alexxu/windtunnel-flow360
alexxu-flex Nov 14, 2025
a8ae8fa
addressed some comments, validation wip
alexxu-flex Nov 17, 2025
adf5cd7
ghost surfaces
alexxu-flex Nov 17, 2025
f86cb90
parameter validation testcases
alexxu-flex Nov 17, 2025
30d84fb
is -> isinstance bug fix
alexxu-flex Nov 17, 2025
f89bb21
added valid test case
alexxu-flex Nov 17, 2025
533f2fd
updated pipeline to support wind tunnel compatibility with solver (on…
alexxu-flex Nov 18, 2025
a1f1563
Merge branch 'main' into alexxu/windtunnel-flow360
alexxu-flex Nov 18, 2025
fc29bc0
merge conflict
alexxu-flex Nov 18, 2025
077799e
switched schema to tuple
alexxu-flex Nov 19, 2025
1271549
worked WindTunnelGhostSurface into pipeline
alexxu-flex Nov 21, 2025
1345331
Merge branch 'main' into alexxu/windtunnel-flow360
alexxu-flex Nov 21, 2025
e726343
formatting
alexxu-flex Nov 21, 2025
5854c60
Merge branch 'alexxu/windtunnel-flow360' of github.com:flexcompute/Fl…
alexxu-flex Nov 21, 2025
492112d
fix test break
alexxu-flex Nov 21, 2025
609e664
added translation tests
alexxu-flex Nov 21, 2025
2894240
formatting
alexxu-flex Nov 21, 2025
91eed98
Merge branch 'main' into alexxu/windtunnel-flow360
benflexcompute Nov 21, 2025
424a07f
minor changes; unifying allowed surfaces list next
alexxu-flex Nov 24, 2025
1e7684c
Merge branch 'alexxu/windtunnel-flow360' of github.com:flexcompute/Fl…
alexxu-flex Nov 24, 2025
3261c7b
made get_valid_ghost_surfaces consistent with @propertys
alexxu-flex Nov 24, 2025
6152c61
added staticmethod for getting boundaries w/o validation
alexxu-flex Nov 24, 2025
e599d96
checked left, right, symmetric plane for half body wind tunnel
alexxu-flex Nov 25, 2025
64a4fc8
Fixed linting
benflexcompute Nov 26, 2025
5ed5f74
merge branch main
alexxu-flex Nov 26, 2025
17c0606
minor fixes
alexxu-flex Nov 26, 2025
2bbb779
pylint duplicate code
alexxu-flex Nov 26, 2025
87cb5ac
addressed feedback
alexxu-flex Nov 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions flow360/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,18 @@
from flow360.component.simulation.meshing_param.volume_params import (
AutomatedFarfield,
AxisymmetricRefinement,
CentralBelt,
CustomZones,
FullyMovingFloor,
MeshSliceOutput,
RotationCylinder,
RotationVolume,
StaticFloor,
StructuredBoxRefinement,
UniformRefinement,
UserDefinedFarfield,
WheelBelts,
WindTunnelFarfield,
)
from flow360.component.simulation.models.material import (
Air,
Expand Down Expand Up @@ -335,6 +340,11 @@
"ImportedSurface",
"OctreeSpacing",
"RunControl",
"WindTunnelFarfield",
"StaticFloor",
"FullyMovingFloor",
"CentralBelt",
"WheelBelts",
]

_warn_prerelease()
9 changes: 5 additions & 4 deletions flow360/component/project_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,10 +168,11 @@ def _replace_the_ghost_surface(*, ghost_surface, ghost_entities_from_metadata):
for item in ghost_entities_from_metadata:
if item.name == ghost_surface.name:
return item
raise Flow360ConfigurationError(
f"Ghost surface `{ghost_surface.name}` is used but likely won't be generated."
" Please double check the use of ghost surfaces."
)
return ghost_surface
# raise Flow360ConfigurationError(
# f"Ghost surface `{ghost_surface.name}` is used but likely won't be generated."
# " Please double check the use of ghost surfaces."
# )

def _find_ghost_surfaces(*, model, ghost_entities_from_metadata):
for field in model.__dict__.values():
Expand Down
11 changes: 8 additions & 3 deletions flow360/component/simulation/meshing_param/params.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
StructuredBoxRefinement,
UniformRefinement,
UserDefinedFarfield,
WindTunnelFarfield,
)
from flow360.component.simulation.primitives import SeedpointVolume
from flow360.component.simulation.validation.validation_context import (
Expand Down Expand Up @@ -60,6 +61,7 @@
AutomatedFarfield,
UserDefinedFarfield,
CustomZones,
WindTunnelFarfield,
],
pd.Field(discriminator="type"),
]
Expand Down Expand Up @@ -162,13 +164,14 @@ class MeshingParams(Flow360BaseModel):

@pd.field_validator("volume_zones", mode="after")
@classmethod
def _check_volume_zones_has_farfied(cls, v):
def _check_volume_zones_has_farfield(cls, v):
if v is None:
# User did not put anything in volume_zones so may not want to use volume meshing
return v

total_farfield = sum(
isinstance(volume_zone, (AutomatedFarfield, UserDefinedFarfield)) for volume_zone in v
isinstance(volume_zone, (AutomatedFarfield, WindTunnelFarfield, UserDefinedFarfield))
for volume_zone in v
)
if total_farfield == 0:
raise ValueError("Farfield zone is required in `volume_zones`.")
Expand Down Expand Up @@ -275,11 +278,13 @@ def _check_no_reused_volume_entities(self) -> Self:

@property
def farfield_method(self):
"""Returns the farfield method used."""
"""Returns the farfield method used."""
if self.volume_zones:
for zone in self.volume_zones: # pylint: disable=not-an-iterable
if isinstance(zone, AutomatedFarfield):
return zone.method
if isinstance(zone, WindTunnelFarfield):
return "wind-tunnel"
if isinstance(zone, UserDefinedFarfield):
return "user-defined"
return None
Expand Down
Loading
Loading