textual inversion
In plain wordsTeaching an image generator a new 'word' for a specific object or style from a few example pictures, leaving the model itself unchanged — only one vocabulary entry is added.
A personalization method that teaches a frozen text-to-image modeltext-to-image model, n.: An AI system that creates a picture from a written description, such as 'a fox reading a newspaper, in watercolor', usually within seconds. a new concept — a particular object, person or artistic style — by adding one invented word (a pseudo-word such as S*) to its vocabulary and learning nothing but that word's embeddingembedding, n.: A list of numbers that stands for a word, picture or other item, arranged so that similar items get similar lists. It lets a computer measure similarity of meaning as distance., after which any prompt containing the word evokes the concept. Starting from typically three to five example images, it optimizes the single vector in the text encoder's input space against the model's ordinary denoising loss while every network weight stays fixed; the authors reported that one such vector was enough for a wide range of concepts. The resulting files are a few kilobytes and can be shared and combined, and the community also trains 'negative embeddings' that encode unwanted features for use in negative promptsnegative prompt, n.: A second prompt listing what you do not want in a generated image — 'blurry, extra fingers, watermark' — which the generator then steers away from.. Fidelity is lower than with weight-updating methods such as DreamBoothDreamBooth, prop. n.: A way to teach an image generator one specific subject — your dog, your face, a product — from a handful of photos, so it can draw that exact subject in new scenes. or LoRAlow-rank adaptation, n.: A cheap way to customize a big AI model: instead of changing all its billions of numbers, you train a small add-on of a few million numbers that slightly adjusts how it behaves., because a single token cannot inject what the model cannot already express.
Origin
Introduced by Rinon Gal and colleagues at Tel Aviv University and NVIDIA in 'An Image is Worth One Word' (posted August 2022; ICLR 2023), first demonstrated on latent diffusion models and quickly adopted for Stable Diffusion.
Usage note
Not related to model inversionmodel inversion, n.: Using a trained AI model's answers to work backwards to private information it learned from — for example, rebuilding a recognizable picture of someone's face from a face-recognition system., a privacy attack; 'inversion' here means finding the text embedding that would generate the given images.
Related
- DreamBoothDreamBooth, prop. n.: A way to teach an image generator one specific subject — your dog, your face, a product — from a handful of photos, so it can draw that exact subject in new scenes.
- embeddingembedding, n.: A list of numbers that stands for a word, picture or other item, arranged so that similar items get similar lists. It lets a computer measure similarity of meaning as distance.
- prompt tuningprompt tuning, n.: Teaching a frozen language model a new task by learning a few made-up 'words' — lists of numbers rather than real text — that are placed before the input to steer the model.
- negative promptnegative prompt, n.: A second prompt listing what you do not want in a generated image — 'blurry, extra fingers, watermark' — which the generator then steers away from.
- Stable DiffusionStable Diffusion, prop. n.: A widely used image-generating AI whose model files were released for anyone to download, so people could run it on their own computers and adapt it.
- low-rank adaptationlow-rank adaptation, n.: A cheap way to customize a big AI model: instead of changing all its billions of numbers, you train a small add-on of a few million numbers that slightly adjusts how it behaves.
- DreamBoothDreamBooth, prop. n.: A way to teach an image generator one specific subject — your dog, your face, a product — from a handful of photos, so it can draw that exact subject in new scenes.
Sources
- Gal, R., Alaluf, Y., Atzmon, Y., Patashnik, O., Bermano, A. H., Chechik, G. & Cohen-Or, D. (2023). An Image is Worth One Word: Personalizing Text-to-Image Generation using Textual Inversion. ICLR 2023. arXiv:2208.01618. arxiv.org/abs/2208.01618
Mentioned in
Stable DiffusionStable Diffusion, prop. n.: A widely used image-generating AI whose model files were released for anyone to download, so people could run it on their own computers and adapt it., DreamBoothDreamBooth, prop. n.: A way to teach an image generator one specific subject — your dog, your face, a product — from a handful of photos, so it can draw that exact subject in new scenes.