code: def test_zero_diag():
      ones = torch.ones(10, 10)
      ones_zd = zero_diag(ones)
      assert ones_zd.shape == (10, 10)
      assert float(ones_zd.trace()) == 0
      assert float(ones_zd.sum()) == 90
  
imports: from itertools import product
  import pytest
  import torch
  import numpy
  from alibi_detect.utils.pytorch import zero_diag, quantile
label_desc: Use image node_id 1 for calling a global function with example usage: test_zero_diag() without return types