MCDC icon indicating copy to clipboard operation
MCDC copied to clipboard

Visualizer crashes on 3D C5G7 and SMRG7

Open spasmann opened this issue 1 year ago • 0 comments

Using latest version of MCDC, after inserting mcdc.visualize() after defining the geometry in the 3D C5G7 and SMRG7 input decks I get the following error

(mcdc-vis-env) PS C:\Users\Sam\Documents\Github\Experiments\3d_c5g7> python .\input.py
optfile ./ng.opt does not exist - using default values
togl-version : 2
OCC module loaded
loading ngsolve library
NGSolve-6.2.2307
Using Lapack
Including sparse direct solver Pardiso
Running parallel using 16 thread(s)
Traceback (most recent call last):
  File "C:\Users\Sam\Documents\Github\Experiments\3d_c5g7\input.py", line 272, in <module>
    mcdc.visualize()
  File "C:\Users\Sam\mambaforge\envs\mcdc-vis-env\Lib\site-packages\mcdc\visualizer.py", line 435, in visualize
    color_key_dic = draw_Geometry(
                    ^^^^^^^^^^^^^^
  File "C:\Users\Sam\mambaforge\envs\mcdc-vis-env\Lib\site-packages\mcdc\visualizer.py", line 318, in draw_Geometry
    cell_geometry = create_cell_geometry(
                    ^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Sam\mambaforge\envs\mcdc-vis-env\Lib\site-packages\mcdc\visualizer.py", line 233, in create_cell_geometry
    math.sqrt(abs(surface_list[surface_ID]["J"][0, 0] - z**2 - y**2))
                                                        ^
UnboundLocalError: cannot access local variable 'z' where it is not associated with a value

Any ideas @RohanPankaj ?

spasmann avatar Feb 07 '24 23:02 spasmann