code: def eval_fun(fun, *args):
      def read(v):
          return env[v]
  
      def write(v, x):
          env[v] = x
  
      env = {}
      map(write, fun.in_vars, args)
      for in_vars, out_vars, f in fun.eqns:
          out_vals = f(*map(read, in_vars))
          map(write, out_vars, out_vals)
  
      return map(read, fun.out_vars)
  
imports: from collections import namedtuple
  from functools import partial
  import numpy.random
  from absl.testing import absltest
  from absl.testing import parameterized
  import itertools
  import jax.numpy
  from jax import jit, jvp, vjp
  import jax._src.test_util
  from jax import config
  from jax._src.util import unzip2, safe_zip, safe_map
label_desc: Use image node_id 3 for calling a global function with example usage: eval_fun(fun) and returns: map, env