parameters: (base64ImgString)
return_statement: return pil_img
docstring: Converts a base64 encoded image to PIL image 
  
      Arguments:
          base64ImgString {string} -- Encoded base64 image string
  
      Returns:
          PIL -- PIL image
docstring_summary: Converts a base64 encoded image to PIL image
docstring_tokens: Converts a base64 encoded image to PIL image
function: def base64ToPilImg(base64ImgString):
      """Converts a base64 encoded image to PIL image 
  
      Arguments:
          base64ImgString {string} -- Encoded base64 image string
  
      Returns:
          PIL -- PIL image
      """
      from PIL import Image
      if base64ImgString.startswith('b\''):
          base64ImgString = base64ImgString[2:-1]
      base64Img   =  base64ImgString.encode('utf-8')
      decoded_img = base64.b64decode(base64Img)
      img_buffer  = io.BytesIO(decoded_img)
      pil_img = Image.open(img_buffer).convert('RGB')
      return pil_img
function_tokens: def base64ToPilImg ( base64ImgString ) : from PIL import Image if base64ImgString . startswith ( 'b\'' ) : base64ImgString = base64ImgString [ 2 : - 1 ] base64Img = base64ImgString . encode ( 'utf-8' ) decoded_img = base64 . b64decode ( base64Img ) img_buffer = io . BytesIO ( decoded_img ) pil_img = Image . open ( img_buffer ) . convert ( 'RGB' ) return pil_img