code: def init_meshes(
      num_meshes: int = 10,
      num_verts: int = 1000,
      num_faces: int = 3000,
      device: str = "cpu",
      add_texture: bool = False,
  ):
      device = torch.device(device)
      verts_list = []
      faces_list = []
      texts_list = []
      for _ in range(num_meshes):
          verts = torch.rand(
              (num_verts, 3), dtype=torch.float32, device=device
          )
          faces = torch.randint(
              num_verts,
              size=(num_faces, 3),
              dtype=torch.int64,
              device=device,
          )
          texts = torch.rand(
              (num_verts, 3), dtype=torch.float32, device=device
          )
          verts_list.append(verts)
          faces_list.append(faces)
          texts_list.append(texts)
  
      # create textures
      textures = None
      if add_texture:
          textures = TexturesVertex(texts_list)
      meshes = Meshes(
          verts=verts_list, faces=faces_list, textures=textures
      )
  
      return meshes
  
imports: import unittest
  import numpy
  import torch
  from PIL import Image
  from pytorch3d.io import load_objs_as_meshes
  from pytorch3d.ops import sample_points_from_meshes
  from pytorch3d.renderer import TexturesVertex
  from pytorch3d.renderer.cameras import FoVPerspectiveCameras, look_at_view_transform
  from pytorch3d.renderer.mesh.rasterize_meshes import barycentric_coordinates
  from pytorch3d.renderer.points import NormWeightedCompositor, PointsRasterizationSettings, PointsRasterizer, PointsRenderer
  from pytorch3d.structures import Meshes, Pointclouds
  from pytorch3d.utils.ico_sphere import ico_sphere
  from .common_testing import get_pytorch3d_dir, get_random_cuda_device, get_tests_dir, TestCaseMixin
label_desc: Use image node_id 1 for calling a global function with example usage: init_meshes(num_meshes, num_verts, num_faces, device, add_texture) and returns: meshes