Hi, first post here and new to Darktable. I’m really liking Darktable having tried pretty much everything else (e.g. Photo Supreme, ACDSee etc). This is probably a very easy thing but I’ve been unable to work out how to do it. I’ve edited the ‘Pattern for thumbnail extended overlay text’ to show what I need but I can’t seem to add the file size - I can’t find it in the list of variables. I have quite a few duplicates and it makes sense to choose the largest image to save. I’m probably missing something very simple here and I’d be glad of your help. Thanks
I am unsure why you would have larger file sizes unless you have done cropping. I do a lot of cropping and want to know the size after cropping so I can estimate what size it is suitable to print at. The variables I use for that are shown here. I have added the x and px at the end of each variable so it makes sense to me. The forum has done something weird to the font but you will get the idea.
(WIDTH.CROP)x(HEIGHT.CROP)px
I think those size categories are the size of the thumbnail, and I think the original question is related to file size. I don’t see a variable for file size.
Yes, to be honest my collection is a mess which evolved over years, which I’m trying to sort out and rationalise. So there are files which might be 10mb and old identical thumbnails (I can’t even remember how they were generated but possibly by the Photo Supreme app). Obviously I need to keep the original 10mb file not the old thumbnail and in order to do that for a lot of files I need to quickly be able to tell which is the original, large file and which a reduced thumbnail or version. Sometimes there will be a TIFF file with an identical small JPG and again the same thing applies.
It also applies to similar but not identical files, where I may have taken a photo with my X-T2 (which doesn’t have GPS) and then taken another with my iPhone so that I have the location data.
I used DT’s copy and import option to acquire many years worth of images from various external drives, CDs, DVDs etc and sort them into folders ultimate based on the day of capture. I then was able to go through each folder and delete duplicates and get rid of rubbish images. It took time but it organised a mess into a much better organised system. I use the same approach now to import pictures from my camera SD cards and order them into my system.
Thanks Terry. the photos are already consolidated and sorted into folders based on date of capture (though I also have several hundred images scanned from transparencies which all have the same incorrect date - but that’s another issue). So I’m going through the same process you went through and hoping to arrive at the same happy conclusion. Being able to see the file size would be a big help in doing this.
The pixel size should be representative of the expected file size. Of course some images of the same pixel dimensions could have different compression rates applied for JPG images. Maybe using file explorer if you have a windows computer would let you check file size, but I do see how file size would be a useful variable for your task. Maybe a feature request could be made to include this as a variable.
Thanks again Terry. I’m on a Mac so I could check file sizes in the Finder. I’ll make a feature request to include file size as a variable - I’m sure others would find it useful. In Photo Supreme for example it’s shown as standard on every thumbnail.
I can see the value of it. I would use it myself. My main purpose would be understanding the difference between Tiff, PNG and other file exporting options.
You’re right, my bad. Kind regards Jetze
I can’t seem to add the file size…it makes sense to choose the largest image to save.
It depends on what you mean by “largest image”—do you mean you have multiple images that are the exact same length and width but they are different compressions or formats so they are different file sizes (10mb vs 1.2mb, for example), or do you mean they are indeed different image sizes (4680 x 2332 vs 2800 x 1200)?
If you mean image size, you need just either the length or width since image size is simply width x height. Whichever is the larger width is the larger image.
The variable you want is $(WIDTH.SENSOR) – the image below has the width of each image (outlined in a red rectangle—you could even have that info printed in red on your overlay to make it easier to find), and I can easily tell which is which by the width. Depending on how the duplicate was made there might also be other clues, such as the missing aperture, ISO, etc. data. For me, if I have a TIFF, I know it’s a duplicate. If I have a RAF and a JPG of the same image, the JPG is the duplicate. If I have grouped images, the group leader is the duplicate because I never change which is the group leader. Etc.
Maybe some of that helps?
My collection is an unholy mess of many years making so I guess all of the above could be appropriate! I see the logic of what you write but I think you are coming at it from the point of view of someone who already has a logically ordered collection whereas I’m at the beginning of that process trying to bring order out of chaos. Add to that that several hundred scans from transparencies which all inevitably have the wrong date (date of scan rather than date image was taken). I currently have about 8k untagged images (10k tagged) and there are many duplicates or near duplicates which I’m trying to cull.
That sure looks like a donkey job Rhod, Please ignore this rant when not helpful.
You are new to darktable and have partly tagged pictures. Do you know already whether those tags are accessible for darktable when you import them? That might make it easier to work. And did you already import all picture files you’ve gotten into darktable?
Have you already determined a standard folder structure? Standard may be a folder for each day you’ve taken pictures (yyyymmdd-description). Or one folder for all…. Or a folder per filetype… Or a folder per subject… You’ll need a base structure to work on.
You’ll need access to every bit of info and as much as possible tools to work with. Two monitors to display files will help. Part of the job might be done outside darktable in your filemanager or whatever you have. Having multiple programs - multiple filemanagers together with darktable - in view may help a great deal.
Maybe it is useful to analyse which info is left to you? I mean things like:
- Identical filenames with a different filetype. Those may indicate a master-slave relation, or the same origin.
- Or maybe you are able to analyze date taken fields. See ‘image information’ in darktable
- Or maybe the camera that took the picture is in the info. See ‘image information’ in darktable
- Or maybe the create, save dates are accessible to you which may be helpful.
- Series of pictures exported as thumbnails or for a website maybe recognizable and set apart as secondary file.
Things like that.
You might design a structured set of keywords in darktable that will help you keeping track of files. Something like
- Top keyword “Cleanup_25” (applied to all pictures but not to pictures newly taken). And then the level below it
- “Status_25” and in that
- “To_be_sorted_out”,
- “Sorted_out” and
- “Impossible_to_sort_out”, whatever is practical.
- And beside “Status_25” you might have something like “Type_25” and under that
- “Type_Original_RAW” and maybe further split into Raw and Transparancy,
- “Type_Secondary_File”,
- “Type_Undetermined” and
- whatever you may need.
- “Status_25” and in that
This set of keywords will help you to keep track of where you are in your process.
In darktable you may group files when they belong to the same origin. Or use keywords for that. That may help as well.
Assuming the 10k tagged are not part of the problem I would set them apart with a keyword (sorted_out) to set them apart.
Assuming the transparencies are easy to set apart, having some kind of naming convention/specific file type and probably no doublures with respect to content with other files you may set them apart as well and - if my assumptions are right - tag them with: ‘transparency’ and ‘sorted_out’.
Then you may set apart groups of pictures according to file type, starting with the highest quality files, maybe RAW’s, maybe TIF’s - or both - as they contain the most/best information and are probably the source of some smaller jpegs / thumbnails.
There seems to be no - one size fits all solution. It will take time and then you’ll have seen all old pictures and made them accessible.
Hope it helps - ask questions when needed as probably all is new to you.
Kind regards, Jetze
There is a lot there to take in so I will respond more fully in due course but I just wanted to say thanks so much for going to all that trouble! It will certainly help in my deliberations of what is indeed a mammoth task but one which I am at last determined to get sorted. Thanks again!
You’re welcome,
Take your time, glad to be helpful. And it is indeed a lot of work. When done right it might enable you to easily retrieve any picture you are searching for. Lovely winter project…
In my feeling at least you need to know when and where a picture is taken and what is the subject (may be ‘land- or cityscape’,‘our daughter’ etc.). I often add to that a why, like ‘beautiful evening’, ‘fine light’, ‘beautiful leaves’ or whatever. And of course some starring and labeling is being done. With some thinking and trying you’ll find your own convenient way.
You might give yourself the present of having marked your best pictures which then darktable will help you to nicely develop.
And please do ask questions when the manual or internet do not provide the answers.


