liveBook · Manning

Digital image

As explained in Data Analysis with LLMs

Image data is data represented as visual images containing depicted objects, people, scenes, or other visual information.

A digital image is visual data representing depicted objects, people, scenes, or other visual information. It can be analyzed alongside text, video, audio, and tables. section 1.2 section 6.0

A practical image-processing workflow treats images as files that can be loaded, compared, analyzed, and organized:

  • Load PNG files from input directories and represent them as filename-to-image dictionaries. section 6.3.4
  • Encode locally stored image bytes as base64 strings before sending them with text instructions. section 6.3.4
  • Compare images with multimodal prompts that define both the task and the expected answer. section 6.3.1 section 6.3.4
  • Write analysis results into an output directory, using filenames to represent discovered tags. section 6.3.1

Tagging people in pictures

Given reference images named Joe.png and Jane.png, compare each reference with a beach.png file. If both people appear, create Joebeach.png and Janebeach.png in the output directory, making related pictures searchable by filename. section 6.3.1

Figure 6.2 Multimodal prompt containing two images and text: the prompt instructs the language model to check whether the two pictures show the same person (expected answer: “Yes”) or not (expected answer: “No”).
figure

Use the multimodal prompt figure to see how two images and text instructions produce a Yes-or-No comparison. section 6.3.1

How Data Analysis with LLMs covers it

How deep it goes
Explains files, PNG filtering, base64 encoding, dictionaries, pairwise comparison, prompts, and output naming without discussing image internals.
Examples
Uses PNG files, reference portraits, beach.png, filename prefixes, base64 strings, and Yes-or-No comparison prompts.
What it assumes
Assumes local image directories and filenames, while introducing image loading, encoding, prompting, and pairwise comparison.
What you can do after
Build image-processing applications with Python, GPT-4o, multimodal prompts, local directories, and the requests API.
How it connects
Connects digital images to multimodal data analysis, language models, prompts, image comparison, tagging, and video data.

Also explained in

Compare how 16 books explain digital image →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Data Analysis with LLMs. The section links point to the parts of the book it draws on.