code: def test_list_of_images_to_tensor(num_of_images, image_shape):
      images: List[np.array] = []
      if num_of_images == 0:
          with pytest.raises(ValueError):
              kornia.utils.image_list_to_tensor([])
          return
      for _ in range(num_of_images):
          images.append(np.ones(shape=image_shape))
      if len(image_shape) != 3:
          with pytest.raises(ValueError):
              kornia.utils.image_list_to_tensor(images)
          return
      tensor = kornia.utils.image_list_to_tensor(images)
      assert tensor.shape == (
          num_of_images,
          image_shape[-1],
          image_shape[-3],
          image_shape[-2],
      )
  
file_path: kornia/test/utils/test_image_utils.py
imports: from typing import List
  import numpy
  import pytest
  import torch
  import kornia
  from kornia.testing import assert_close
label_desc: Use image node_id 2 for calling a global function with example usage: test_list_of_images_to_tensor(num_of_images, image_shape) without return types