From e7eb1016d80336836b9ee7f18bccc0c0605cab46 Mon Sep 17 00:00:00 2001 From: Pablo Brubeck Date: Fri, 15 Nov 2024 14:12:51 +0000 Subject: [PATCH] sort_domains --- firedrake/assemble.py | 4 ++-- firedrake/slate/slate.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/firedrake/assemble.py b/firedrake/assemble.py index 75ed1f85af..d3f4cfb8ba 100644 --- a/firedrake/assemble.py +++ b/firedrake/assemble.py @@ -1628,7 +1628,7 @@ def _integral_type(self): @cached_property def _mesh(self): - return tuple(self._form.ufl_domains())[self._kinfo.domain_number] + return self._form.ufl_domains()[self._kinfo.domain_number] @cached_property def _needs_subset(self): @@ -1970,7 +1970,7 @@ def _indexed_function_spaces(self): @cached_property def _mesh(self): - return tuple(self._form.ufl_domains())[self._kinfo.domain_number] + return self._form.ufl_domains()[self._kinfo.domain_number] @cached_property def _iterset(self): diff --git a/firedrake/slate/slate.py b/firedrake/slate/slate.py index 01943faead..85b7af3635 100644 --- a/firedrake/slate/slate.py +++ b/firedrake/slate/slate.py @@ -31,7 +31,7 @@ from ufl.algorithms.map_integrands import map_integrand_dags from ufl.corealg.multifunction import MultiFunction from ufl.classes import Zero -from ufl.domain import join_domains +from ufl.domain import join_domains, sort_domains from ufl.form import Form import hashlib @@ -983,7 +983,7 @@ def ufl_domains(self): the tensor. """ collected_domains = [op.ufl_domains() for op in self.operands] - return join_domains(chain(*collected_domains)) + return sort_domains(join_domains(chain(*collected_domains))) def subdomain_data(self): """Returns a mapping on the tensor: