code: def test_ref_compare_rand(backend_default, refgruargs):
      # run comparison with reference code
      # for Gaussian random init
      seq_len, input_size, hidden_size, batch_size = refgruargs
      NervanaObject.be.bsz = NervanaObject.be.batch_size = batch_size
  
      try:
          check_rnn(
              seq_len, input_size, hidden_size, batch_size, Gaussian()
          )
      except Exception:
          # xfail for cpu backend on pascal
          if not isinstance(NervanaObject.be, NervanaCPU):
              check_rnn(
                  seq_len,
                  input_size,
                  hidden_size,
                  batch_size,
                  Gaussian(),
              )
          else:
              if os.getenv("PLATFORM"):
                  platform = os.getenv("PLATFORM")
              else:
                  if os.path.exists("/proc/cpuinfo"):
                      cat_cmd = "cat /proc/cpuinfo | grep \"model name\" | tail -1 | cut -f 2 -d ':' | \
                             cut -f 3 -d ')' | cut -f 1 -d '@' | cut -f 2,3 -d ' '"
                      cpu_model_name = subp.check_output(
                          cat_cmd, shell=True
                      )
                  else:
                      cpu_model_name = "unknown"
  
              if (
                  cpu_model_name == "CPU E5-2699A\n"
                  or b"CPU E5-2699A\n"
              ):
                  platform = "BDW"
              else:
                  platform = "unknown"
  
              if platform == "BDW":
                  pytest.xfail(
                      reason="xfail issue #1041 with {} PLATFORM".format(
                          platform
                      )
                  )
              else:
                  check_rnn(
                      seq_len,
                      input_size,
                      hidden_size,
                      batch_size,
                      Gaussian(),
                  )
  
file_path: neon/tests/test_recurrent.py
imports: import os
  import pytest
  import subprocess
  import itertools
  import numpy
  from neon import NervanaObject, logger
  from neon.initializers.initializer import Constant, Gaussian
  from neon.layers import Recurrent
  from neon.layers.container import DeltasTree
  from neon.transforms import Tanh
  from recurrent_ref import Recurrent
  from utils import allclose_with_out
label_desc: Use image node_id 3 for calling a global function with example usage: test_ref_compare_rand(backend_default, refgruargs) without return types