Skip to content

capjamesg/image-collage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Image Collage Generator

Generate a collage of images where a specific object of interest is focused.

This project uses a zero-shot object detection model, Grounding DINO, to identify regions corresponding to objects of interest. These regions are then cropped and stitched together into a collage.

Here is an example of a collage generated by this project:

grid

Usage

First, install this project from source:

git clone https://github.com/capjamesg/image-collage
cd image-collage
pip3 install -r requirements.txt

To generate a collage, run:

python3 app.py --input_images=folder/with/images --prompt="object" --confidence=0.7

Above, set:

  • input_images to the name of a directory with all the images you want to stich together into a collage.
  • prompt to the object of interest you want to identify.
  • confidence to the minimum confidence a model prediction must be to be considered for inclusion in the image collage.

License

This project is licensed under an MIT license.