From cb63ab01c4d46cc2ae84814f39467e8aadc0b9b1 Mon Sep 17 00:00:00 2001 From: Thorsten Liebig Date: Sun, 5 Mar 2023 20:33:07 +0100 Subject: [PATCH] python: fix automesh type detection Signed-off-by: Thorsten Liebig --- python/openEMS/automesh.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/openEMS/automesh.py b/python/openEMS/automesh.py index 295dec7..80baabd 100644 --- a/python/openEMS/automesh.py +++ b/python/openEMS/automesh.py @@ -25,9 +25,9 @@ def mesh_combine(mesh1, mesh2, sort=True): return mesh def mesh_hint_from_primitive(primitive, dirs, **kw): - if primitive.GetType() is CSPrimitives.POINT: + if primitive.GetType() == CSPrimitives.POINT: return mesh_hint_from_point(primitive, dirs, **kw) - if primitive.GetType() is CSPrimitives.BOX: + if primitive.GetType() == CSPrimitives.BOX: return mesh_hint_from_box(primitive, dirs, **kw) else: return None