code: def metrics(y_ref, y, epsilon=1e-6):
      y_ref = y_ref.float()
      y = y.float()
      relerr, mse = (
          (y_ref - y).abs().sum() / (y_ref.abs().sum() + epsilon),
          (y_ref - y).square().mean(),
      )
      return relerr.item(), mse.item()
  
file_path: apex/apex/contrib/test/layer_norm/test_fast_layer_norm.py
imports: import itertools
  import unittest
  import torch
label_desc: Use image node_id 2 for calling a global function with example usage: metrics(y_ref, y, epsilon) and returns: relerr,  mse