code: def test_contains_self_loops():
      edge_index = torch.tensor([[0, 1, 0], [1, 0, 0]])
      assert contains_self_loops(edge_index)
  
      edge_index = torch.tensor([[0, 1, 1], [1, 0, 2]])
      assert not contains_self_loops(edge_index)
  
file_path: pytorch_geometric/test/utils/test_loop.py
imports: import torch
  from torch_geometric import EdgeIndex
  from torch_geometric.utils import add_remaining_self_loops, add_self_loops, contains_self_loops, get_self_loop_attr, remove_self_loops, segregate_self_loops, to_torch_coo_tensor
label_desc: Use image node_id 1 for calling a global function with example usage: test_contains_self_loops() without return types