code: def one_hot_encoding(
      target,
      n_classes,
      on_value=1.0,
      off_value=0.0,
      name="OneHotEncoding",
  ):
      """One Hot Encoding.
  
      Transform numeric labels into a binary vector.
  
      Input:
          The Labels Placeholder.
  
      Output:
          2-D Tensor, The encoded labels.
  
      Arguments:
          target: `Placeholder`. The labels placeholder.
          n_classes: `int`. Total number of classes.
          on_value: `scalar`. A scalar defining the on-value.
          off_value: `scalar`. A scalar defining the off-value.
          name: A name for this layer (optional). Default: 'OneHotEncoding'.
  
      """
  
      with tf.name_scope(name):
          if target.dtype != dtypes.int64:
              target = standard_ops.to_int64(target)
  
          target = standard_ops.one_hot(
              target, n_classes, on_value=on_value, off_value=off_value
          )
  
      # Track output tensor.
      tf.add_to_collection(
          tf.GraphKeys.LAYER_TENSOR + "/" + name, target
      )
  
      return target
  
imports: from __future__ import division, print_function, absolute_import
  import numpy
  import tensorflow.compat.v1
  from tensorflow.python.framework import dtypes
  from tensorflow.python.ops import standard_ops
  import tflearn
  from tflearn import utils
  from tflearn import variables
  from tflearn import activations
  from tflearn import initializations
  from tflearn import regularizers
label_desc: Use image node_id 10 for calling a global function with example usage: one_hot_encoding(target, n_classes, on_value, off_value, name) and returns: target