Skip to content

Topologies mismatch on operators

Weak requirements on fields can lead to topology mismatch. (See job failure https://gricad-gitlab.univ-grenoble-alpes.fr/particle_methods/hysop/-/jobs/34939)

Get from output, regarding enstrophy operator

==[0] ComputationalGraph Problem topology report ======================================================================
 :OpenClBackend:  tag=bk2, cl_env=clenv0, allocator=OpenClImmediateAllocator::al0, host_backend=HostArrayBackend::bk0]:
  *CartesianTopology[tag=t1, domain=Box::d0, pcoords=[0 0 0], pshape=[1 1 1], shape=[65,65,65], ghosts=[4,4,4]]
  *CartesianTopology[tag=t2, domain=Box::d0, pcoords=[0 0 0], pshape=[1 1 1], shape=[65,65,65], ghosts=[0,0,0]]
=======================================================================================================================
==[0] ComputationalGraph Problem fields report ==================================================================================================================================================================================
>FIELD U::υ
   BACKEND   TOPOLOGY   OPERATORS
   opencl    t1         Rυ₀→₁, Tυ_xzy, Tυ_yzx, advec_X₀, advec_X₁, advec_Y₀, advec_Y₁, advec_Z₀, advec_Z₁, stretch_diffuse_X₀, stretch_diffuse_X₁, stretch_diffuse_Y₀, stretch_diffuse_Y₁, stretch_diffuse_Z₀, stretch_diffuse_Z₁, |υ|∞
>FIELD WdotW::ω⋅ω
   BACKEND   TOPOLOGY   OPERATORS
   opencl    t2         enstrophy
>FIELD W::ω
   BACKEND   TOPOLOGY   OPERATORS
   opencl    t1         Rω₀→₁, Rω₁→₀, Tω_xzy, Tω_yzx, advec_X₀, advec_X₁, advec_Y₀, advec_Y₁, advec_Z₀, advec_Z₁, enstrophy, stretch_diffuse_X₀, stretch_diffuse_X₁, stretch_diffuse_Y₀, stretch_diffuse_Y₁, stretch_diffuse_Z₀, stretch_diffuse_Z₁, |ω|∞
=================================================================================================================================================================================================================================
==[0] ComputationalGraph Problem discrete operator report ==========================================
  ID  OPERATOR                   INPUTS                 OUTPUTS         OPERATOR TYPE      
  28  enstrophy                  [ω.t₁]            ->   [ω⋅ω.t₂]x[ζ]    OpenClEnstrophy            
====================================================================================================

The internal field WdotW is created with 0 ghosts as allowed by enstrophy's field requirements. But W has already be discretized with topology t1 with 4 ghosts in an other operator.

As enstrophy operator can onle deal with single topology, this lead to the runtime error :

packages/hysop/operator/base/enstrophy.py", line 94, in discretize
    assert self.dWdotW.topology == self.dWin.topology
AssertionError
Edited by EXT Jean-Matthieu Etancelin
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information