AI engineering glossary · Computer vision

What is patch embedding?

Patch embedding: The first step of a vision transformer: cut the image into equal square patches, flatten each and project it with a learned linear layer into a vector, giving the tokens the transformer reads.

Level: advancedTopic: Computer vision

Patch embedding: an example

A 16 x 16 x 3 patch has 768 raw values, which is projected to a 768-dimensional embedding in ViT-Base.

Related terms

More Computer vision terms

Where you learn it

Patch embedding is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.

Before you go

Take the cheat sheet with you

One free PDF: the key AI-engineering terms, formulas and Python idioms. No spam; unsubscribe any time.