code: def grad_to_image(gradient):
      """Convert gradients of image obtained using `get_image_grad`
      into image. This shows parts of the image that is most strongly activating
      the output neurons."""
      gradient = gradient - gradient.min()
      gradient /= gradient.max()
      gradient = onp.uint8(gradient * 255).transpose(1, 2, 0)
      gradient = gradient[..., ::-1]
      return gradient
  
imports: from __future__ import print_function
  import mxnet
  from mxnet import gluon, np, npx
  from mxnet import autograd
  from mxnet.gluon import nn
  import numpy
  import cv2
label_desc: Use image node_id 6 for calling a global function with example usage: grad_to_image(gradient) and returns: gradient