Giter Site home page Giter Site logo

collage_maker's Introduction

Collage maker

Picture collage maker in Python

Usage:

The usage of collage_maker.py is very simple:

usage: collage_maker.py [-h] [-f FOLDER] [-o OUTPUT] [-w WIDTH]
                        [-i INIT_HEIGHT] [-s]

Photo collage maker

optional arguments:
  -h, --help            show this help message and exit
  -f FOLDER, --folder FOLDER
                        folder with images (*.jpg, *.jpeg, *.png)
  -o OUTPUT, --output OUTPUT
                        output collage image filename
  -w WIDTH, --width WIDTH
                        resulting collage image width
  -i INIT_HEIGHT, --init_height INIT_HEIGHT
                        initial height for resize the images
  -s, --shuffle         enable images shuffle

Example:

collage_maker.py -o my_collage.png -w 800 -i 250 -s

Description:

Description of algorithm is available in my blog: http://delimitry.blogspot.com/2014/07/picture-collage-maker-using-python.html

License:

Released under The MIT License.

collage_maker's People

Contributors

delimitry avatar jgiubardo avatar sushain97 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

collage_maker's Issues

No PIL package available in pypi

image
Please find the above issue while using PIL , please see if your code can work with some other image library other than PIL and Image

[Feature] Process archive files. similar to folders

Had anyone tried to process zip other type of archives in same manner as folders currently?
By default script uses paths to gather file list, and so far my attempts to create such list for files in zip work not as I'm expecting.

ValueError: unknown file extension:

There are only jpg but, I get this after a while:

โžœ  collage_maker git:(master) python3 collage_maker.py -f /ImagesAll -o /ImagesAll -w 20000 -i 50 -s
Making collage...
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/PIL/Image.py", line 2144, in save
    format = EXTENSION[ext]
KeyError: ''

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/collage_maker/collage_maker.py", line 118, in <module>
    main()
  File "/collage_maker/collage_maker.py", line 110, in main
    res = make_collage(images, args.output, args.width, args.init_height)
  File "/collage_maker/collage_maker.py", line 80, in make_collage
    collage_image.save(filename)
  File "/usr/local/lib/python3.9/site-packages/PIL/Image.py", line 2146, in save
    raise ValueError(f"unknown file extension: {ext}") from e
ValueError: unknown file extension:

Even there is no .DS_Store - find . -name '.DS_Store' -type f -delete

Resize only, not crop

Hi, loving this.
Is there a way to make sure that all of the image is included even if some are very small. But not missing information. The title says it, resize not crop?

Really appreciate it

Limit the height of the image with another parameter

Hi
Is it also possible to limit the height and not only the width?
I tried to implement it myself and add another parameter but I didn't really find out where to add the check and resize the images after. I know the repo is quite old, but if you still have knowledge about this script, would be awesome.

thanks in advance

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.