code: def test_coco_annotation(self):
      from sahi.utils.coco import CocoAnnotation
  
      coco_segmentation = [[1, 1, 325, 125, 250, 200, 5, 200]]
      category_id = 3
      category_name = "car"
      coco_annotation = CocoAnnotation.from_coco_segmentation(
          segmentation=coco_segmentation,
          category_id=category_id,
          category_name=category_name,
      )
  
      self.assertAlmostEqual(coco_annotation.area, 41177, 1)
      self.assertEqual(coco_annotation.bbox, [1, 1, 324, 199])
      self.assertEqual(coco_annotation.category_id, category_id)
      self.assertEqual(coco_annotation.category_name, category_name)
      self.assertEqual(coco_annotation.segmentation, coco_segmentation)
  
      coco_bbox = [1, 1, 100, 100]
      category_id = 3
      coco_annotation = CocoAnnotation.from_coco_bbox(
          bbox=coco_bbox,
          category_id=category_id,
          category_name=category_name,
      )
  
      self.assertEqual(coco_annotation.area, 10000)
      self.assertEqual(coco_annotation.bbox, coco_bbox)
      self.assertEqual(coco_annotation.category_id, category_id)
      self.assertEqual(coco_annotation.category_name, category_name)
      self.assertEqual(coco_annotation.segmentation, [])
  
imports: import os
  import shutil
  import unittest
  from sahi.utils.coco import merge, update_categories
  from sahi.utils.file import load_json
label_desc: Use image node_id 2 for calling the TestCocoUtils obj's underlying member method code with example usage: obj.test_coco_annotation() without return types