    def forward(self, x: Tensor) -> Tensor:
        """
        Args:
            x (Tensor): Input tensor.
        """
        B, N, C = x.shape()
        if self.cls_embed_on:
            cls_tokens = ops.expand()(self.cls_token.tensor(), [B, -1, -1])
            x = ops.concatenate()([cls_tokens, x], dim=1)

        if self.sep_pos_embed:
            pos_embed = ops.elementwise(FuncEnum.ADD)(
                repeat(
                    self.pos_embed_spatial.tensor(), (1, self.num_temporal_patch, 1)
                ),
                repeat_interleave(
                    self.pos_embed_temporal.tensor(), self.num_spatial_patch, dim=1
                ),
            )

            if self.cls_embed_on:
                pos_embed = ops.concatenate()(
                    [self.pos_embed_class.tensor(), pos_embed], dim=1
                )
            x = ops.elementwise(FuncEnum.ADD)(x, pos_embed)
        else:
            x = ops.elementwise(FuncEnum.ADD)(x, self.pos_embed.tensor())

        return x
Args:
x (Tensor): Input tensor.
python/aitemplate/frontend/nn/positional_encoding.py