code: def init_weight(self):
      super().init_weight()
      param_init.constant_init(self.sampling_offsets.weight, value=0.0)
      thetas = paddle.arange(self.num_heads, dtype="float32") * (
          2.0 * math.pi / self.num_heads
      )
      grid_init = paddle.stack([thetas.cos(), thetas.sin()], -1)
      grid_init = paddle.tile(
          (
              grid_init / grid_init.abs().max(-1, keepdim=True)[0]
          ).reshape((self.num_heads, 1, 1, 2)),
          (1, self.num_levels, self.num_points, 1),
      )
      for i in range(self.num_points):
          grid_init[:, :, i, :] *= i + 1
      paddle.nn.initializer.Assign(grid_init.flatten())(
          self.sampling_offsets.bias
      )
      self.sampling_offsets.bias.stop_gradient = True
  
      param_init.constant_init(self.attention_weights.weight, value=0.0)
      param_init.constant_init(self.attention_weights.bias, value=0.0)
      param_init.xavier_uniform(self.value_proj.weight)
      param_init.constant_init(self.value_proj.bias, value=0.0)
      param_init.xavier_uniform(self.output_proj.weight)
      param_init.constant_init(self.output_proj.bias, value=0.0)
  
imports: from __future__ import absolute_import
  from __future__ import print_function
  from __future__ import division
  import math
  import paddle
  import paddle.nn
  import paddle.nn.functional
  from paddleseg.cvlibs import param_init
  from paddlepanseg.models.param_init import THLinearInitMixin
  from paddlepanseg.utils import use_custom_op
label_desc: Use image node_id 2 for calling the MSDeformAttn obj's underlying member method code with example usage: obj.init_weight() without return types