class_docstr: 2D Image to Patch Embedding
class_docstr_tok: ["2D","Image","to","Patch","Embedding"]
code: def call(self, x, **kwargs):
      _, H, W, _ = x.shape
  
      # padding
      # 如果输入图片的H，W不是patch_size的整数倍，需要进行padding
      pad_input = (H % self.patch_size[0] != 0) or (
          W % self.patch_size[1] != 0
      )
      if pad_input:
          paddings = tf.constant(
              [
                  [0, 0],
                  [0, self.patch_size[0] - H % self.patch_size[0]],
                  [0, self.patch_size[1] - W % self.patch_size[1]],
              ]
          )
          x = tf.pad(x, paddings)
  
      # 下采样patch_size倍
      x = self.proj(x)
      B, H, W, C = x.shape
      # [B, H, W, C] -> [B, H*W, C]
      x = tf.reshape(x, [B, -1, C])
      x = self.norm(x)
      return x, H, W
  
imports: import tensorflow
  from tensorflow.keras import Model, layers, initializers
  import numpy
label_desc: Use image node_id 2 for calling the PatchEmbed obj's underlying member method code with example usage: obj.call(x) and returns: x,  H,  W