class_docstr: A simple scene model to demonstrate use of pulsar in PyTorch modules.
  
  The scene model is parameterized with sphere locations (vert_pos),
  channel content (vert_col), radiuses (vert_rad), camera position (cam_pos),
  camera rotation (cam_rot) and sensor focal length and width (cam_sensor).
  
  The forward method of the model renders this scene description. Any
  of these parameters could instead be passed as inputs to the forward
  method and come from a different model.
class_docstr_tok: ["A","simple","scene","model","to","demonstrate","use","of","pulsar","in","PyTorch","modules",".","The","scene","model","is","parameterized","with","sphere","locations","(","vert_pos",")",",","channel","content","(","vert_col",")",",","radiuses","(","vert_rad",")",",","camera","position","(","cam_pos",")",",","camera","rotation","(","cam_rot",")","and","sensor","focal","length","and","width","(","cam_sensor",")",".","The","forward","method","of","the","model","renders","this","scene","description",".","Any","of","these","parameters","could","instead","be","passed","as","inputs","to","the","forward","method","and","come","from","a","different","model","."]
code: def forward(self):
      # The Pointclouds object creates copies of it's arguments - that's why
      # we have to create a new object in every forward step.
      pcl = Pointclouds(
          points=self.vert_pos[None, ...],
          features=self.vert_col[None, ...],
      )
      return self.renderer(
          pcl,
          gamma=(self.gamma,),
          zfar=(45.0,),
          znear=(1.0,),
          radius_world=True,
          bg_col=torch.ones((3,), dtype=torch.float32, device=DEVICE),
          # As mentioned above: workaround for device placement of gradients for
          # camera parameters.
          focal_length=self.focal_length,
          R=self.cam_rot[None, ...],
          T=self.cam_pos[None, ...],
      )[0]
  
file_path: pytorch3d/docs/examples/pulsar_cam_unified.py
imports: import logging
  from os import path
  import cv2
  import imageio
  import numpy
  import torch
  from pytorch3d.renderer.cameras import PerspectiveCameras
  from pytorch3d.renderer.points import PointsRasterizationSettings, PointsRasterizer, PulsarPointsRenderer
  from pytorch3d.structures.pointclouds import Pointclouds
  from pytorch3d.transforms import axis_angle_to_matrix
  from torch import nn, optim
label_desc: Use image node_id 2 for calling the SceneModel obj's underlying member method code with example usage: obj.forward() and returns: self