From fefed5e1aee7805e39b22338e5d7229316e9f08b Mon Sep 17 00:00:00 2001 From: Connor Ward Date: Thu, 24 Oct 2024 11:52:50 +0100 Subject: [PATCH] Use UFL element hashing instead of FInAT element hashing (#3807) * Fixes #3732. --- firedrake/output/vtk_output.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/firedrake/output/vtk_output.py b/firedrake/output/vtk_output.py index b6f7548216..2dc7ab0235 100644 --- a/firedrake/output/vtk_output.py +++ b/firedrake/output/vtk_output.py @@ -453,13 +453,11 @@ def __init__(self, filename, project_output=False, comm=None, mode="w", def _prepare_output(self, function, max_elem): from firedrake import FunctionSpace, VectorFunctionSpace, \ TensorFunctionSpace, Function - from tsfc.finatinterface import create_element as create_finat_element name = function.name() # Need to project/interpolate? # If space is not the max element, we must do so. - finat_elem = function.function_space().finat_element - if finat_elem == create_finat_element(max_elem): + if function.function_space().ufl_element() == max_elem: return OFunction(array=get_array(function), name=name, function=function) # OK, let's go and do it.