code: def __init__(
      self,
      densepose_datas,
      boxes_xyxy_abs,
      image_size_hw,
      device=_TORCH_DEVICE_CPU,
  ):
      assert len(densepose_datas) == len(boxes_xyxy_abs), (
          "Attempt to initialize DensePoseList with {} DensePose datas "
          "and {} boxes".format(
              len(densepose_datas), len(boxes_xyxy_abs)
          )
      )
      self.densepose_datas = []
      for densepose_data in densepose_datas:
          assert (
              isinstance(densepose_data, DensePoseDataRelative)
              or densepose_data is None
          ), (
              "Attempt to initialize DensePoseList with DensePose datas "
              "of type {}, expected DensePoseDataRelative".format(
                  type(densepose_data)
              )
          )
          densepose_data_ondevice = (
              densepose_data.to(device)
              if densepose_data is not None
              else None
          )
          self.densepose_datas.append(densepose_data_ondevice)
      self.boxes_xyxy_abs = boxes_xyxy_abs.to(device)
      self.image_size_hw = image_size_hw
      self.device = device
  
file_path: detectron2/projects/DensePose/densepose/structures/list.py
imports: import torch
  from densepose.structures.data_relative import DensePoseDataRelative
label_desc: Use image node_id 1 to create a new DensePoseList object  with example: obj = DensePoseList(densepose_datas, boxes_xyxy_abs, image_size_hw, device)