CalcElementVector - macOS RuntimeError: std::bad_cast

More
5 years 1 week ago #3110 by creativeworker
Hello,

I use the following code-snippet without any problems on windows.
Code:
for el in fes.Elements(VOL): elvec = f_int_lfi.CalcElementVector (el.GetFE(), el.GetTrafo())
On macOS (installation via conda) Python 3.7.3, ngsolve 6.2.2007 it fails with RuntimeError: std::bad_cast.
I use H1 elements for fes. Anyone a tip where this difference between macOS and Windows could be relevant for this function?

With kind regards,
More
5 years 1 week ago #3113 by joachim
without seeing the full code it's difficult to say whether windows of macOS are right. I am not aware of an essential difference.
More
5 years 1 week ago - 5 years 1 week ago #3122 by creativeworker
I see your point. Up to now I was not able to generate a minimal example that has the same issue. It seems that the function el.GetTrafo() throws the error: *** RuntimeError: std::bad_cast.
Last edit: 5 years 1 week ago by creativeworker. Reason: refining the question.
More
5 years 1 week ago #3123 by creativeworker
Hello,
I now found a perfect minimal example to show the behavior. The attached file runs fine on windows and fails on macOS.
It seems to have something to do with the SetDeformation command on the mesh.
Perhaps this helps you to check what could go wrong here.

File Attachment:

File Name: element_ve...shDef.py
File Size:1 KB
More
5 years 1 day ago #3135 by joachim
fixed in the latest nightly release,
thanks for the report,
Joachim
The following user(s) said Thank You: creativeworker
Time to create page: 0.149 seconds