if i do
argv = sys.argv
print(argv)
and call this code with python it works as expected but with netgen argv is empty. How can i pass Command line arguments ?
Thank you
if i do
argv = sys.argv
print(argv)
and call this code with python it works as expected but with netgen argv is empty. How can i pass Command line arguments ?
Thank you
i have implemented this now as
argv: list[str] = sys.argv
filepath = ""
if len(argv) < 2:
filepath = os.environ.get("ES_ARGV")
else:
filepath = argv[1]
if __name__ == '__main__' and len(filepath) > 0:
mesh = ngsolve.Mesh(filepath)
it seems that netgen does not propagate cmd args to the python interpreter.