code: def test_torch_MSE():
      from bigdl.orca.learn.pytorch.pytorch_metrics import MSE
  
      pred = torch.tensor([[1, -2], [1, 1]])
      target = torch.tensor([[1, 1], [1, 1]])
      m = MSE()
      m(pred, target)
      assert m.compute() == 2.25
      pred = torch.tensor([[1, 1], [1, 1]])
      target = torch.tensor([[1, 1], [0, 1]])
      m(pred, target)
      assert m.compute() == 1.25
      pred = torch.tensor([[1.3, 1.0], [0.2, 1.0]])
      target = torch.tensor([[1.1, 1.0], [0.0, 1.0]])
      m(pred, target)
      assert abs(m.compute() - 0.84) < 1e-7
      pred = torch.tensor([[1.2, 1.2, 1.2, 1.8], [0.2, 0.8, 0.9, 1.1]])
      target = torch.tensor([[1, 1, 1, 2], [0, 1, 1, 1]])
      m(pred, target)
      assert abs(m.compute() - 0.517) < 1e-7
  
file_path: BigDL/python/orca/test/bigdl/orca/learn/test_metrics.py
imports: import torch
  import pytest
label_desc: Use image node_id 7 for calling a global function with example usage: test_torch_MSE() without return types