Skip to content

Commit

Permalink
aboc path
Browse files Browse the repository at this point in the history
  • Loading branch information
GBenedett committed Jan 24, 2024
1 parent 729ac45 commit f8fd12a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions ceasiompy/SUMOAutoMesh/sumoautomesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
SUMOFILE_XPATH,
SUMO_OUTPUT_MESH_FORMAT_XPATH,
EDGE_MESH_XPATH,
EDGE_ABOC_XPATH,
)
from ceasiompy.utils.moduleinterfaces import get_toolinput_file_path, get_tooloutput_file_path
from cpacspy.cpacsfunctions import create_branch, get_value_or_default, open_tixi
Expand Down Expand Up @@ -318,6 +319,13 @@ def create_mesh(cpacs_path, cpacs_out_path):
else:
create_branch(tixi, EDGE_MESH_XPATH)
tixi.updateTextElement(EDGE_MESH_XPATH, str(mesh_out_path))

edge_aboc_path = Path(sumo_results_dir, "ToolOutput.aboc")
shutil.copyfile(mesh_path, edge_aboc_path)

create_branch(tixi, EDGE_ABOC_XPATH)
tixi.updateTextElement(EDGE_ABOC_XPATH, str(edge_aboc_path))

mesh_path.unlink()

tixi.save(str(cpacs_out_path))
Expand Down
1 change: 1 addition & 0 deletions ceasiompy/utils/commonxpath.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@
EDGE_MG_LEVEL_XPATH = EDGE_XPATH + "/settings/multigridLevel"
EDGE_FIXED_CL_XPATH = EDGE_XPATH + "/fixedCL"
EDGE_SOLVER = EDGE_XPATH + "/solver"
EDGE_ABOC_XPATH = EDGE_XPATH + "/boundary_condition"

# RANGE
RANGE_LD_RATIO_XPATH = CEASIOMPY_XPATH + "/ranges/lDRatio"
Expand Down

0 comments on commit f8fd12a

Please sign in to comment.