code: def check_num_annotations(self):
      tasks_num_annotations = self.num_annotations()
      for task, num_annotations in tasks_num_annotations.items():
          if len(set(num_annotations.values())) > 1:
              msg = "\n".join(
                  [
                      f"\t- {v} for {k}"
                      for k, v in num_annotations.items()
                  ]
              )
              raise AutofixAbort(
                  "Number of items should be the same for each annotation type"
                  f", but got for task {task}:\n{msg}"
              )
  
file_path: icevision/icevision/core/record.py
imports: from icevision.imports import *
  from icevision.utils import *
  from icevision.core.exceptions import *
  from icevision.core.components import *
  from icevision.core.record_components import *
label_desc: Use image node_id 3 for calling the BaseRecord obj's underlying member method code with example usage: obj.check_num_annotations() without return types