code: def test_vgae():
      model = VGAE(encoder=lambda x: (x, x))
  
      x = torch.tensor([[1.0, -1.0], [1.0, 2.0], [2.0, 1.0]])
      model.encode(x)
      assert float(model.kl_loss()) > 0
  
      model.eval()
      model.encode(x)
  
      if is_full_test():
          jit = torch.jit.export(model)
          jit.encode(x)
          assert float(jit.kl_loss()) > 0
  
file_path: pytorch_geometric/test/nn/models/test_autoencoder.py
imports: import torch
  from torch import Tensor
  from torch_geometric.data import Data
  from torch_geometric.nn import ARGA, ARGVA, GAE, VGAE
  from torch_geometric.testing import is_full_test
  from torch_geometric.transforms import RandomLinkSplit
label_desc: Use image node_id 2 for calling a global function with example usage: test_vgae() without return types