code: def __init__(
      self,
      in_channels,
      tps_inputsize,
      tps_outputsize,
      num_control_points,
      tps_margins,
      stn_activation,
  ):
      super(STN_ON, self).__init__()
      self.tps = TPSSpatialTransformer(
          output_image_size=tuple(tps_outputsize),
          num_control_points=num_control_points,
          margins=tuple(tps_margins),
      )
      self.stn_head = STN(
          in_channels=in_channels,
          num_ctrlpoints=num_control_points,
          activation=stn_activation,
      )
      self.tps_inputsize = tps_inputsize
      self.out_channels = in_channels
  
file_path: PaddleOCR/ppocr/modeling/transforms/stn.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import math
  import paddle
  from paddle import nn, ParamAttr
  from paddle.nn import functional
  import numpy
  from .tps_spatial_transformer import TPSSpatialTransformer
label_desc: Use image node_id 1 to create a new STN_ON object from inherited base classes: nn with example: obj = STN_ON(in_channels, tps_inputsize, tps_outputsize, num_control_points, tps_margins, stn_activation)