code: def finite_difference(model, closure, eps):
      fd_params = []
      ground = closure()
      for param in model.parameters():
          fd_param = torch.zeros_like(param)
          for p, fdp in zip(param.flatten(), fd_param.flatten()):
              p.data.add_(eps)
              fdp.data.fill_((closure() - ground) / eps)
              p.data.sub_(eps)
          fd_params.append(fd_param)
      return fd_params
  
imports: import unittest
  import copy
  from parameterized import parameterized
  import torch
  from torch import nn, optim
  import higher
label_desc: Use image node_id 1 for calling a global function with example usage: finite_difference(model, closure, eps) and returns: fd_params