code: def hexagon(input_region: List[int]) -> Tuple[List[int], List[int]]:
      """Get coordinates of points inside a hexagon.
  
      Args:
          input_region (List[int]): Region in which to draw the hexagon. [x1, y1, x2, y2]
      Example:
      >>> image = np.full((200,200,3),fill_value=255, dtype=np.uint8)
      >>> patch_region = random_square_patch([100, 100, 200, 200])
      >>> xx, yy = hexagon(patch_region)
      >>> patched = image.copy()
      >>> patched[yy, xx, :] = 1
      >>> plt.imshow(patched)
      Returns:
          Tuple[List[int], List[int]]: Array of cols and rows which denote the mask.
      """
      x1_i, y1_i, x2_i, _ = input_region
  
      cx = (x2_i - x1_i) // 2
      hex_half_side = (
          x2_i - x1_i
      ) // 4  # assume side of hexagon to be 1/2 of the square size
  
      x1, y1 = x1_i + hex_half_side, y1_i
      x2, y2 = x1_i + cx + hex_half_side, y1_i
      x3, y3 = x2_i, y1_i + int(1.732 * hex_half_side)  # 2cos(30)
      x4, y4 = x1_i + cx + hex_half_side, y1_i + int(
          3.4641 * hex_half_side
      )  # 4 * cos(30)
      x5, y5 = x1_i + hex_half_side, y1_i + int(
          3.4641 * hex_half_side
      )  # 4 * cos(30)
      x6, y6 = x1_i, y1_i + int(1.732 * hex_half_side)
      return polygon([x1, x2, x3, x4, x5, x6], [y1, y2, y3, y4, y5, y6])
  
file_path: anomalib/tests/helpers/shapes.py
imports: from typing import List, Tuple
  import numpy
  from skimage.draw import polygon
label_desc: Use image node_id 4 for calling a global function with example usage: hexagon(input_region) and returns: polygon