All models

cvt (base vision transformer)

CvT folds convolutions into a vision transformer for local detail plus global attention.

Image classification · 646 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (33 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Family
cvt
Parameters
19.6M
Operations
646
Framework
PyTorch
Recurrent
No
Name in source
cvt:base-vision-transformer
License
Apache-2.0
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m3998
Graph hash
53497a2f1dee66e605c52858adea271ad1d3bebba2db6d47a75251de81c0bbc5
Skeleton hash
8ceb4339558017727b7ff8c3fcb148ad26c4f5e41d86b32821cf86125a4a3b42
Architecture hash
f82ee6cfa620d2c9175ec92b3b0b13d53f2c4bb61ec52723ef85f6054a8842ad
Diagram SHA-256
c41e0fc62e282ea3daea71563abcedca8db96e84f82b3f196f70b5a1da64cdbe
TorchLens version
2.35.3
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

How this diagram was made

transformers.AutoModel.from_config()

What it is

CvtModel is the bare encoder, with an option to add a pooling layer.

About this model's family

CvT, the Convolutional Vision Transformer, combines the strengths of convolutional neural networks and vision transformers for computer vision tasks. It introduces convolutional layers into the vision transformer architecture, so it can capture local patterns in images while keeping the global context that self-attention provides.

All the CvT checkpoints live under the Microsoft organization on the Hub. The documented example classifies an image through Pipeline or the AutoModel class.

Key idea. Convolutional layers inside a vision transformer, capturing local image patterns while keeping the global context of self-attention.

  • cvt
  • convolutional vision transformer
  • cvt-13
  • image classification
  • microsoft
  • hybrid cnn transformer

AI-written summary, based on the model's documentation and checked automatically against it; not reviewed by a person. Corrections welcome.