class_docstr: Create a image viz
docstr: Construct a Mapviz object
  
  :param coordinates: property to determine image coordinates (UL, UR, LR, LL).
      EX. [[-80.425, 46.437], [-71.516, 46.437], [-71.516, 37.936], [-80.425, 37.936]]
  :param image: url, local path or a numpy ndarray
  :param legend: default setting is to hide heatmap legend
docstr_tok: ["Construct","a","Mapviz","object",":","param","coordinates",":","property","to","determine","image","coordinates","(","UL",",","UR",",","LR",",","LL",")",".","EX",".","[","[","-80.425",",","46.437","]",",","[","-71.516",",","46.437","]",",","[","-71.516",",","37.936","]",",","[","-80.425",",","37.936","]","]",":","param","image",":","url",",","local","path","or","a","numpy","ndarray",":","param","legend",":","default","setting","is","to","hide","heatmap","legend"]
code: def __init__(self, image, coordinates, legend=False, *args, **kwargs):
      """Construct a Mapviz object
  
      :param coordinates: property to determine image coordinates (UL, UR, LR, LL).
          EX. [[-80.425, 46.437], [-71.516, 46.437], [-71.516, 37.936], [-80.425, 37.936]]
      :param image: url, local path or a numpy ndarray
      :param legend: default setting is to hide heatmap legend
  
      """
      super(ImageViz, self).__init__(None, *args, **kwargs)
  
      if type(image) is numpy.ndarray:
          image = img_encode(image)
  
      self.template = "image"
      self.image = image
      self.coordinates = coordinates
  
imports: import codecs
  import json
  import os
  from IPython.core.display import HTML, display
  import numpy
  import requests
  from mapboxgl.errors import TokenError, LegendError
  from mapboxgl.utils import color_map, numeric_map, img_encode, geojson_to_dict_list
  from mapboxgl import templates
label_desc: Use image node_id 1 to create a new ImageViz object from inherited base classes: MapViz with example: obj = ImageViz(image, coordinates, legend)