code: def test_multihead_attention_deterministic(getkey):
      with warnings.catch_warnings():
          attn = eqx.nn.MultiheadAttention(
              num_heads=2, query_size=10, dropout_p=0.5, key=getkey()
          )
          x = jrandom.normal(getkey(), (3, 10))
          warnings.simplefilter("ignore")
          z1 = attn(x, x, x, key=getkey(), deterministic=True)
          z2 = attn(x, x, x, deterministic=True)
          assert jnp.all(z1 == z2)
  
imports: import warnings
  from typing import Union
  import equinox
  import jax
  import jax.nn
  import jax.numpy
  import jax.random
  import pytest
label_desc: Use image node_id 25 for calling a global function with example usage: test_multihead_attention_deterministic(getkey) without return types