code: def save(
      self,
      filename,
      shapes,
      imagePath,
      imageHeight,
      imageWidth,
      imageData=None,
      otherData=None,
      flags=None,
  ):
      if imageData is not None:
          imageData = base64.b64encode(imageData).decode("utf-8")
          imageHeight, imageWidth = self._check_image_height_and_width(
              imageData, imageHeight, imageWidth
          )
      if otherData is None:
          otherData = {}
      if flags is None:
          flags = {}
      data = dict(
          version=__version__,
          flags=flags,
          shapes=shapes,
          imagePath=imagePath,
          imageData=imageData,
          imageHeight=imageHeight,
          imageWidth=imageWidth,
      )
      for key, value in otherData.items():
          assert key not in data
          data[key] = value
      try:
          with open(filename, "w") as f:
              json.dump(data, f, ensure_ascii=False, indent=2)
          self.filename = filename
      except Exception as e:
          raise LabelFileError(e)
  
imports: import argparse
  import collections
  import datetime
  import glob
  import json
  import os
  import os.path
  import sys
  import uuid
  import PIL
  import io
  import base64
  import logging
  import math
  import imgviz
  import numpy
label_desc: Use image node_id 5 for calling the LabelFile obj's underlying member method code with example usage: obj.save(filename, shapes, imagePath, imageHeight, imageWidth, imageData, otherData, flags) without return types