class_docstr: Pooling Pyramid Module used in PSPNet.
  
  Args:
      pool_scales (tuple | list): Pooling scales used in PPM.
      in_channels (int): Input channels.
      channels (int): Output Channels after modules, before conv_seg.
      act_cfg (dict): Config of activation layers.
      align_corners (bool): align_corners argument of F.interpolate.
class_docstr_tok: ["Pooling","Pyramid","Module","used","in","PSPNet",".","Args",":","pool_scales","(","tuple","|","list",")",":","Pooling","scales","used","in","PPM",".","in_channels","(","int",")",":","Input","channels",".","channels","(","int",")",":","Output","Channels","after","modules",",","before","conv_seg",".","act_cfg","(","dict",")",":","Config","of","activation","layers",".","align_corners","(","bool",")",":","align_corners","argument","of","F.interpolate","."]
code: def __init__(self, pool_scales, in_channels, channels, align_corners):
      super().__init__()
      self.pool_scales = pool_scales
      self.in_channels = in_channels
      self.channels = channels
      self.align_corners = align_corners
      self.stages = nn.LayerList()
      for pool_scale in pool_scales:
          self.stages.append(
              nn.Sequential(
                  nn.AdaptiveAvgPool2D(
                      output_size=(pool_scale, pool_scale)
                  ),
                  ConvBNReLU(
                      in_channels=in_channels,
                      out_channels=channels,
                      kernel_size=1,
                  ),
              )
          )
  
imports: import paddle
  import paddle.nn
  import paddle.nn.functional
  from paddleseg import utils
  from paddleseg.cvlibs import manager
  from paddleseg.models import layers
label_desc: Use image node_id 1 to create a new PPM object from inherited base classes: nn with example: obj = PPM(pool_scales, in_channels, channels, align_corners)