Upgrade to Pro — share decks privately, control downloads, hide ads and more …

More Than Pixels

More Than Pixels

Ever wanted to analyze your pixels and not just get some histograms, gradients or edges out of it?

Vision-Language Models (VLMs) are here to help!

In my talk I give two use-cases for VLMs and how they can be used to analyze images.

The slides are very visual without much text, so it might not be inherently clear what is going on for everyone ;)

Johannes Kolbe

October 22, 2024
Tweet

More Decks by Johannes Kolbe

Other Decks in Programming

Transcript

  1. About Me JOHANNES KOLBE DATA SCIENTIST AT CELEBRATE COMPANY ML

    GENERALIST M.SC. IN COMPUTER SCIENCE AT TU BERLIN HUGGING FACE FELLOW AI EDUCATOR COMMUNITY COMPUTER VISION COURSE SPEAKER AT PYDATA LONDON, EUROPYTHON, PYTHON PIZZA HAMBURG, PYCON AFRICA linkedin.com/in/johko/ github.com/johko
  2. Captured An Orca jumping out of the water. A lighthouse

    standing among rocks An impressive octopus. A giant wave breaking. Two seagulls flying in the sky.
  3. Datasets Datasets Local Files (csv, json, text, images, audio) Pre-built

    Datasets from HF Hub Datasets Data Structures (dicts, dataframes, ...)
  4. (Detailed) Captioning The image shows a wild boar walking through

    a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion.
  5. The image shows a wild boar walking through a forest.

    The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. Text Clustering The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion.
  6. The image shows a wild boar walking through a forest.

    The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. Topic Modeling The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion.
  7. BERTopic The image shows a wild boar walking through a

    forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion.
  8. BERTopic The image shows a wild boar walking through a

    forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. Picture of a Boar Picture of a Cheetah Picture of Birds Picture of Unknown
  9. The image shows a wild boar walking through a forest.

    The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. BERTopic LLM
  10. The image shows a wild boar walking through a forest.

    The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. Workflow The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion.
  11. The image shows a wild boar walking through a forest.

    The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. Workflow The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion.
  12. The image shows a wild boar walking through a forest.

    The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion. Workflow The image shows a wild boar walking through a forest. The boar is dark brown in color and appears to be walking on a bed of fallen leaves and twigs. It is walking towards the right side of the image, with its head down and its mouth slightly open. The background is filled with trees and foliage, and there is a small bird feeder hanging from one of the trees. The image is taken from a distance, and the boar's body is slightly blurred, indicating that it is in motion.
  13. Code siglip_model = SiglipModel.from_pretrained("google/siglip-base-patch16-224") siglip_processor = AutoProcessor.from_pretrained("google/siglip-base-patch16-224") siglip_tokenizer = AutoTokenizer.from_pretrained("google/siglip-base-patch16-224")

    def create_image_embeddings(images, model, processor): inputs = processor(images=images, return_tensors="pt") model = model.to(device) inputs = inputs.to(device) with torch.no_grad(): image_embeds = model.get_image_features(**inputs) return image_embeds.view(-1)
  14. Code def create_text_embedding(text, model, tokenizer): padding = "max_length" inputs =

    tokenizer(text, return_tensors="pt", padding=padding) inputs.to(device) model.to(device) with torch.no_grad(): text_embeds = model.get_text_features(**inputs) return text_embeds.view(-1).tolist()
  15. dataset = load_dataset("ceyda/fashion-products-small") dataset = dataset.map(embed_images) dataset.add_faiss_index(column="image_embeddings") query = create_text_embedding(“A

    picture of a boar”, siglip_model, siglip_tokenizer) scores, retrieved_examples = ds_with_embeddings.get_nearest_examples("image_embeddings", query, k=10) retrieved_examples[”image”][0] Code
  16. Code def infer_florence2(self, images, model, processor): task_prompt = "<DESCRIPTION>" prompt

    = task_prompt + "Describe this image in great detail." inputs = processor( images=images, text=[prompt] * len(images), return_tensors="pt", ).to(self.device) outputs = model.generate( input_ids=inputs["input_ids"], pixel_values=inputs["pixel_values"], max_new_tokens=1024, num_beams=3, ) generated_texts = processor.batch_decode(outputs, skip_special_tokens=False)
  17. Code processed_texts = [] for text in generated_texts: parsed_answer =

    processor.post_process_generation( text, task=task_prompt, image_size=(image_batch[0].width, image_batch[0].height), ) modified_text = self.modify_caption_florence2(parsed_answer["<DESCRIPTION>"]) processed_texts.append(modified_text) created_captions.extend(processed_texts)