code: def generate_normalized_grid_2d(B, size, align_corners):
      H, W = size
      hgrid = np.linspace(-1.0, 1.0, H)
      wgrid = np.linspace(-1.0, 1.0, W)
      hgrid = hgrid if align_corners else hgrid * (H - 1) / H
      wgrid = wgrid if align_corners else wgrid * (W - 1) / W
      w, h = np.meshgrid(wgrid, hgrid)
  
      x = w.reshape(-1)
      y = h.reshape(-1)
      t = np.ones(len(x))
      normalized_grid = np.stack((x, y, t), axis=1)
      normalized_grid = normalized_grid.reshape(H, W, 3)
      normalized_grid = np.repeat(
          normalized_grid[np.newaxis, :, :, :], B, axis=0
      )
      return normalized_grid.astype(np.float32)
  
imports: from __future__ import division
  from six.moves import range
  import itertools
  import numpy
label_desc: Use image node_id 16 for calling a global function with example usage: generate_normalized_grid_2d(B, size, align_corners) and returns: normalized_grid