class_docstr: ViT for clip
  Args:
      input_resolution (int): input resolution
      patch_size (int): patch size
      width (int): width
      layers (int): number of layers
      heads (int): number of heads
      output_dim (int): output dimension
      vis (bool): visualization
      is_bridgeformer (bool): is bridge model or not
      is_bridge_former_video (bool): text transformer or visual transformer for a single frame
code: def __init__(
      self,
      input_resolution: int,
      patch_size: int,
      width: int,
      layers: int,
      heads: int,
      output_dim: int,
      vis: bool = False,
      is_bridgeformer: bool = False,
      is_bridge_former_video: bool = False,
  ):
      super().__init__()
      self.input_resolution = input_resolution
      self.output_dim = output_dim
      self.is_bridgeformer = is_bridgeformer
      self.conv1 = nn.Conv2d(
          in_channels=3,
          out_channels=width,
          kernel_size=patch_size,
          stride=patch_size,
          bias=False,
      )
  
      scale = width**-0.5
      self.class_embedding = nn.Parameter(scale * torch.randn(width))
      self.patch_nums = (input_resolution // patch_size) ** 2
      self.positional_embedding = nn.Parameter(
          scale * torch.randn(self.patch_nums + 1, width)
      )
      self.ln_pre = LayerNorm(width)
  
      self.transformer = Transformer(
          width,
          layers,
          heads,
          vis=vis,
          patch_nums=self.patch_nums,
          is_bridge_former_video=is_bridge_former_video,
      )
  
      self.ln_post = LayerNorm(width)
      self.proj = nn.Parameter(scale * torch.randn(width, output_dim))
  
imports: import os
  import warnings
  from collections import OrderedDict
  from typing import Tuple, Union, Callable
  import numpy
  from PIL import Image
  import torch
  from torch import nn
  from torchvision.transforms import Compose, Resize, CenterCrop, ToTensor, Normalize
  from towhee.models.utils.download import download_from_url
  from towhee.models.clip.clip_utils import get_configs, convert_weights, patch_device, patch_float, tokenize
  from towhee.models.clip.auxilary import multi_head_attention_forward, MultiheadAttention
label_desc: Use image node_id 1 to create a new VisionTransformer object from inherited base classes: nn with example: obj = VisionTransformer(input_resolution, patch_size, width, layers, heads, output_dim, vis, is_bridgeformer, is_bridge_former_video)