class_docstr: Calculate the silhouette by blending the top K faces for each pixel based
  on the 2d euclidean distance of the center of the pixel to the mesh face.
  
  Use this shader for generating silhouettes similar to SoftRasterizer [0].
  
  .. note::
  
      To be consistent with SoftRasterizer, initialize the
      RasterizationSettings for the rasterizer with
      `blur_radius = np.log(1. / 1e-4 - 1.) * blend_params.sigma`
  
  [0] Liu et al, 'Soft Rasterizer: A Differentiable Renderer for Image-based
      3D Reasoning', ICCV 2019
class_docstr_tok: ["Calculate","the","silhouette","by","blending","the","top","K","faces","for","each","pixel","based","on","the","2d","euclidean","distance","of","the","center","of","the","pixel","to","the","mesh","face",".","Use","this","shader","for","generating","silhouettes","similar","to","SoftRasterizer","[","0","]",".","..","note",":",":","To","be","consistent","with","SoftRasterizer",",","initialize","the","RasterizationSettings","for","the","rasterizer","with","`","blur_radius","=","np.log","(","1",".","\/","1e-4","-","1",".",")","*","blend_params.sigma","`","[","0","]","Liu","et","al",",","'Soft","Rasterizer",":","A","Differentiable","Renderer","for","Image-based","3D","Reasoning","'",",","ICCV","2019"]
docstr: Only want to render the silhouette so RGB values can be ones.
  There is no need for lighting or texturing
docstr_tok: ["Only","want","to","render","the","silhouette","so","RGB","values","can","be","ones",".","There","is","no","need","for","lighting","or","texturing"]
code: def forward(
      self, fragments: Fragments, meshes: Meshes, **kwargs
  ) -> torch.Tensor:
      """
      Only want to render the silhouette so RGB values can be ones.
      There is no need for lighting or texturing
      """
      colors = torch.ones_like(fragments.bary_coords)
      blend_params = kwargs.get("blend_params", self.blend_params)
      images = sigmoid_alpha_blend(colors, fragments, blend_params)
      return images
  
imports: import warnings
  from typing import Optional
  import torch
  import torch.nn
  from ...common.datatypes import Device
  from ...structures.meshes import Meshes
  from ..blending import BlendParams, hard_rgb_blend, sigmoid_alpha_blend, softmax_rgb_blend
  from ..lighting import PointLights
  from ..materials import Materials
  from ..splatter_blend import SplatterBlender
  from ..utils import TensorProperties
  from .rasterizer import Fragments
  from .shading import _phong_shading_with_pixels, flat_shading, gouraud_shading, phong_shading
label_desc: Use image node_id 2 for calling the SoftSilhouetteShader obj's underlying member method code with example usage: obj.forward(fragments, meshes) and returns: images