NameError: global name 'dolfin_path' is not defined

6 months ago by
Hi there ,I am trying to run mesh generation code( available in this repo in FEniCS stable:1.6.0 (
When ever i attempt to run the following part of code
def save_mesh_as_vtk():
    from dolfin import FunctionSpace, File
    from fenicshotools import load_geometry
    for t in range(1,16):
               domain, marker = load_geometry(mpi_comm_world(), dolfin_path, "Frame_{}".format(t))
               vtk_file = File("vtk_file.pvd".format(t))
               vtk_file <<, float(t)
i get error : NameError: global name 'dolfin_path' is not defined.  Can anyone please suggest the reason or change in syntax.
Community: FEniCS Project

1 Answer

6 months ago by
Looking at just this portion of your code, the variable dolfin_path is not defined, but you are passing it as the second input to a function in the following line:
domain, marker = load_geometry(mpi_comm_world(), dolfin_path, "Frame_{}".format(t))​
Please login to add an answer/comment or follow this question.

Similar posts:
Search »