code: def weight_variable(shape):
      """weight_variable generates a weight variable of a given shape."""
      initial = tf.truncated_normal(shape, stddev=0.1)
      return tf.Variable(initial)
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import time
  import tensorflow
  from tensorflow.examples.tutorials.mnist import input_data
  import ray
  import ray.experimental.tf_utils
  from bigdl.dllib.utils.log4Error import invalidInputError
label_desc: Use image node_id 5 for calling a global function with example usage: weight_variable(shape) and returns: tf