Gthumpy: Images and Metadata
1.    About Gthumpy
1.    Supported platforms
1.    How to use it
1.    What directory layout should I use?
2.    Keyboard Shortcuts for editMetadata
3.    About
3.    Which files get created?
3.    JavaScript
3.    UnicodeError: UTF-8 decoding error: invalid data
3.    Templates
3.    How do the created HTML files look like?
4.    How can you translate it an other language?
4.    What libraries/programs does gthumpy use?
4.    What licence is used by gthumpy?
4.    There are already many scripts, which do things like this. Why did you do it again?
4.    Where do I post corrections, typos and feedback?
4.    Where can I get it?

1 Introduction [toc]

Gthumpy is small collection of scripts for handling images from a digital camera. One script lets you enter metadata and view picture (date, description, title) in a GUI and an other creates static HTML files and thumbnails.

The created HTML files don't need a http server or CGI, you can burn a CD/DVD and give this to your friends. You only need a webbrowser to view the created HTML files. Gthumpy gets developed on Linux, but should be portable to win32. The HTML files created with "" can be viewed on any platform with a webbrowser.
 Step 1:

 Create a directory with all images which belong to one group.
 If you use the current date like in the example, the directories
 are always sorted in chronological order.


 > cd image-dir
 > mkdir 2004-12-31  # or mkdir `date --iso`
 > cd $_
 > gphoto2 --get-all-files

 If your camera is supported by gphoto, you can use the "get" button to this step.

 Step 2:

 Then have a look at the pictures, rotate, delete and give description
 with "". This is a pygtk GUI:

 > python image-dir/2004-04-14

 You can create a "gthumpy.conf" in "~/.config/gthumpy/gthumpy.conf" or in the
 source directory. You can set the lanuage and the
 image-directory. Look at the default config file.

 > python

 This scripts creates thumbnails with convert of ImageMagick and HTML
 pages. This script behaves like the unix tool "make". If a picture
 gets changed, the thumbnails get created again.
I use a directory for each day I download the images from the camera to the computer.

At the moment I have 3553 pictures in 111 directories.

2 [toc]

This script is a GUI written with pygtk.

The metadata (date, title, description) are saved in a file per image (IMAGE.gthumpy)

You can display all pictures of a directory (incl. metadata):

You can change the directory and give each directory a description:

3 make-my-pictures [toc]

This script creates static HTML files from the metadata. There is a page which lists all directories, a page which lists all pictures of a directory and a page for each image. Taken the example layout from above, this files will be created:
 image-dir/index.html                    # Table with descriptions of all directories
                                         # Created by

 image-dir/2006-01-03/index.html         # Preview with thumbnails.
                                         # Lists all images of the directory.
                                         # Created by

 image-dir/2006-01-03/IMG1_res150.jpg    # Thumbnails
 image-dir/2006-01-03/IMG1_res500.jpg    # Created by

 image-dir/2006-01-03/IMG1.html          # HTML-Page for one image
                                         # created by

 image-dir/2006-01-03/IMG1.gthumpy       # XML file created by
There is one simple JavaScript method. It marks the text where you link points you (...#FOO in the URL). This is usefull if you have a lot of pictures in one directory or a lot of directories in you image-dir. The default encoding for XML is UTF-8. You should use <?xml version="1.0" encoding="iso-8859-1"?> as the first line of your foo.gthumpy files if you want to use german umlauts. Edit "template.gthumpy"

4 Misc [toc]

At the moment german (de) and english (en) are supported. You need to create a new file in the language directory "lang" and edit the templates. Have a look at "". Gthumpy is in the public domain. You can use it under any open source licence. If you like it, send me an email!
  1. Most scripts for HTML pages need a http server. I want to create HTML pages as simple static files.
  2. I like python programming.