Skip to content

Element Quality with auto-meshing #48

@mmegally

Description

@mmegally

Description

Error: MMG5_minQualCheck: too bad quality for the worst element: (elt 49214 -> 0.000000e+00)

Traceback (most recent call last):
File "C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\utils\remeshing\remesh.py", line 536, in remesh_surface
subprocess.check_call(executable_list)
File "C:\Users\micha\miniconda3\envs\svv\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\utils\remeshing\Windows\mmgs_O3.exe', 'tmp.mesh', '-v', '1', '-hsiz', '0.0035423998394562674']' returned non-zero exit status 1.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "", line 1, in
File "C:\Users\micha\Downloads\Simulations\Pyvista Scripts\sample_baffle\Sample_Baffle.py", line 22, in
sim.build_meshes(fluid=True,tissue=True,boundary_layer=False)
File "C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\simulation\simulation.py", line 97, in build_meshes
fluid_surface_mesh = self.synthetic_object.export_solid(watertight=True)
File "C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\tree\tree.py", line 296, in export_solid
model = build_watertight_solid(self)
File "C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\tree\export\export_solid.py", line 733, in build_watertight_solid
model = union_tubes(tubes, lines, cap_resolution=cap_resolution)
File "C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\tree\export\export_solid.py", line 708, in union_tubes
model = remesh_surface(model, hsiz=hsize)
File "C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\utils\remeshing\remesh.py", line 562, in remesh_surface
subprocess.check_call(executable_list)
File "C:\Users\micha\miniconda3\envs\svv\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['C:\Users\micha\miniconda3\envs\svv\lib\site-packages\svv\utils\remeshing\Windows\mmgs_O3.exe', 'tmp.mesh', '-v', '1', '-hsiz', '0.0035423998394562674']' returned non-zero exit status 1.

Reproduction

import pyvista as pv
from svv.domain.domain import Domain
from svv.tree.tree import Tree

mesh = pv.read('sample_baffle_extrude_allometric3_repaired2.stl').triangulate()
baffle = Domain(mesh)
baffle.create()
baffle.solve()
baffle.build()

t = Tree()
t.set_domain(baffle)
t.parameters.set('root_pressure',100)
t.parameters.set('terminal_pressure',0)
t.set_root()
t.n_add(10)

from svv.simulation.simulation import Simulation

sim = Simulation(t)
sim.build_meshes(fluid=True,tissue=True,boundary_layer=False)
sim.extract_faces()

sim.construct_3d_fluid_simulation()
sim.write_3d_fluid_simulation()

Expected behavior

generate mesh files

Additional context

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct and Contributing Guidelines

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions