code: def test_draw_invalid_boxes():
      img_tp = ((1, 1, 1), (1, 2, 3))
      img_wrong1 = torch.full((3, 5, 5), 255, dtype=torch.float)
      img_wrong2 = torch.full((1, 3, 5, 5), 255, dtype=torch.uint8)
      img_correct = torch.zeros((3, 10, 10), dtype=torch.uint8)
      boxes = torch.tensor(
          [
              [0, 0, 20, 20],
              [0, 0, 0, 0],
              [10, 15, 30, 35],
              [23, 35, 93, 95],
          ],
          dtype=torch.float,
      )
      boxes_wrong = torch.tensor(
          [[10, 10, 4, 5], [30, 20, 10, 5]], dtype=torch.float
      )
      labels_wrong = ["one", "two"]
      colors_wrong = ["pink", "blue"]
  
      with pytest.raises(TypeError, match="Tensor expected"):
          utils.draw_bounding_boxes(img_tp, boxes)
      with pytest.raises(ValueError, match="Tensor uint8 expected"):
          utils.draw_bounding_boxes(img_wrong1, boxes)
      with pytest.raises(
          ValueError, match="Pass individual images, not batches"
      ):
          utils.draw_bounding_boxes(img_wrong2, boxes)
      with pytest.raises(
          ValueError,
          match="Only grayscale and RGB images are supported",
      ):
          utils.draw_bounding_boxes(img_wrong2[0][:2], boxes)
      with pytest.raises(ValueError, match="Number of boxes"):
          utils.draw_bounding_boxes(img_correct, boxes, labels_wrong)
      with pytest.raises(ValueError, match="Number of colors"):
          utils.draw_bounding_boxes(
              img_correct, boxes, colors=colors_wrong
          )
      with pytest.raises(ValueError, match="Boxes need to be in"):
          utils.draw_bounding_boxes(img_correct, boxes_wrong)
  
imports: import os
  import re
  import sys
  import tempfile
  from io import BytesIO
  import numpy
  import pytest
  import torch
  import torchvision.transforms.functional
  import torchvision.utils
  from common_utils import assert_equal, cpu_and_cuda
  from PIL import __version__, Image, ImageColor
  from torchvision.transforms.v2.functional import to_dtype
label_desc: Use image node_id 11 for calling a global function with example usage: test_draw_invalid_boxes() without return types