3

I want to measure (not qualitatively but quantitatively) how much "red" are different tomatoes (I can see one is more red than another but how much?).

So I thought I could shoot a photo of every tomato using a reference color chart inside my every photograph calibrate my photographs using the included color chart and after measure how much "red" they are.

Any ideas/suggestions on how to achieve this with GIMP? How do I calibrate each image using the color reference chart included in each photograph? What to use for "redness" measurement? I just want to put data in Excel file and make statistical analysis to prove for example that tomatoes from farm A are more red than farm B.

Edit: In this scenario I do not need to calibrate my monitor or printer. I need 2 things:

  1. consistent color in different photos as color data in the image files; I must compare selected areas in different photos "how red they are"

  2. a way to calculate the redness of a selected area in a photo so that it (without disturbing other colors) correlates with how red it is as seen by a human observer. The calculation formula should become to the same conclusion as a human observer when the rednesses of 2 different images are compared. The formula has the data in the photos, the imagined human observer would have side by side the the photographed objects.

I admit that tomatoes were a cover. Actually I'm interested in the redness of the gills of harvested fish. If someone knows how that red is formed it can help to present a good redness measure.

10
  • as a reference color card i will use this in every photo: oktostore.com/… – Vyron Georgalas Apr 26 at 6:20
  • If you have a camera which can shoot using manual settings, and shoot them all at the same time under the same lighting conditions, with the same white balance setting, then each photo will be exactly the same exposure and colour balance, then you could sample the colours and find out which is the reddest, negating the need to calibrate using a card. Also note the colour of tomatoes depends on their ripeness, so not sure you would "prove" anything about farm A versus farm B's tomatoes. Also this isn't a graphic design question. Maybe more suitable for Photography Stack Exchange. – Billy Kerr Apr 26 at 10:31
  • Measure how red something is? There's already an answer (by @xenoid) which hints that's not so clear. He's right. You cannot measure something which still hasn't a well defined measure. And if it happens that your numeric formula for the redness isn't generally accepted before this offensive by trusted researchers all your measurements can be stamped to be beforehand decided propaganda. – user287001 Apr 26 at 10:52
  • @user287001 - maybe better to say "it could easily be dismissed as false equivocation". The whole premise here that one can "prove" something about the redness of tomatoes from one farm versus another is false. I grow tomatoes. The colour of a tomato depends on how ripe it is, when it was picked, how long it has been ripening, etc. Even tomatoes from the same plant can be different shades of red. It might even be down to different varieties of tomato. Some aren't even red when ripe. This exercise would prove nothing. Just that tomatoes can be different shades of green/yellow/red. – Billy Kerr Apr 26 at 11:11
  • Gentlemen,Thank you very much for your inputs, please do not fosilize so much on the "tomato" subject it was just an example: What actually i need to measure is how red is the color of the gills in fish after harvest (i thought tomato was a better example), i am having a continuous debate about them with other colleagues but it is really difficult to "speak" the same language when one sees "red", another "blood red", another "spent red" etc etc. So i wanted to be able to measure that in some way. – Vyron Georgalas Apr 26 at 11:18
2

Interesting question but it is a more complex issue than you probably imagine at first sight.

Take the same tomatoes; not two different ones but the exact same. Take one photo, and then turn off the lights... and take a second photo. The first image will surely look redder than the second one.

You can do the same with different light situations, a sodium vapor light, fluorescent light, or on a sunny day.

The first basic parameter you need to define is the quality of the light. One quick reference is CRI https://en.wikipedia.org/wiki/Color_rendering_index

The second is exposure. In my example, you can also overexpose the image and you will have no red, but white.

Another parameter is the light environment. Depending on how glossiness a surface is, you could be seeing whiteness on a reflection, or darkness in a shadow.

Ok, let me assume you have all it covered.


What you need to do is prepare is a color-managed photoshoot. You need a color target of good quality.

1. Use one like Xrite's Color Checker. There are other brands, like Datacolor, but I am not sure if it works the same.

Do not use one with too few color targets. That will produce an inaccurate adjustment. Color checker classic has 18 color patches. The one you posted has only 6. It has no information on how to make a curve.

2. Take your photos in RAW.

3. Use either an incident light meter or a gray card to get a proper exposure.

4. Use diffuse light, so you can have better control over the light - shadows fallout. Put the light source at a good distance from the object.

5. Forget GIMP, you need to use a RAW image processor, like Lightroom. Look for some tutorials for this specific step on youtube.

The specific step would include calibration for each photoshoot assuming you are taking the photos in different environments. If you have a controlled light situation, like a photographic studio, you can do it one time for all photoshoots.

6. Now, finally you have something to compare the images. Take a sample on a similar angular area.

7. Define the parameters of your data. Put each RGB value on a separate column or read the HSB values. Probably the "Redder" will be a combination between Saturation and Hue. The most saturated value on the right Hue angle.


Or get one colorimeter or spectrometer: https://www.amazon.com/s?k=colorimeter


Thinking about the project it sounds like a very wet working environment for the color checker, and the color patches are very susceptible to stains with will shift the tone. See if the colorimeter is waterproof or resistant.

Some ideas in order to standardize the project using a camera.

Think of the project as a "forensic lab", and think of real standardized situations, especially if you have several locations.

  1. Use the same brand and model of camera and lens. Use them in manual mode, define the white balance always as sunlight. Shot in RAW.

  2. Get a ring flash of a good reputable brand so you have consistent light temperature and quality. Define a standard power given a standardized distance. I am thinking something like a dentist would use.

  3. Prepare a standardized background. As I am imagining the working environment, it could be some middle gray, directly from the paint bucket, not a prepared one. This way you maximize the viability whenever you need to re-paint or paint a new location. You could also use some defined color of Formica or some other HPL High-pressure laminated brand. Use a satin finish over a glossy one. Do not use a matte finish. If you can have some strips like the ones you see on a forensic shot, with some color references for exposure, a white target and a black one would be nice.

  4. On one clean location or lab, you can make some standard tests, Optimal distance, test the ring flashes, the variables, measure the neutrality of the background gray, use your color checker, etc.

  5. Capacitation is also a key factor. The people in charge of the quality should have a standardized workflow. For example, draining the humidity of the product to some degree to minimize reflections or something, the angle of the camera, etc.


But I still think a colorimeter will be a better option.

5
  • Ideally you create a chart with all the tomato/gills colors, and put it in the frame when taking you pictures. Then you don't need any color adjustment, you just find the color the chart which is the closest to the color of the tomato/gills. – xenoid Apr 26 at 22:07
  • Facepalm... Good Idea! – Rafael Apr 27 at 14:35
  • I apologize for not being able to reply earlier. – Vyron Georgalas May 14 at 9:09
  • 1
    I would like to thank everyone for their input, I think the colorimeter would be best suited for my needs. The problem with the photographs is that it seems very diffiuclt to standardize the procedure in order to insert it in a production cycle. – Vyron Georgalas May 14 at 9:21
  • I added some ideas to standardize your working environment. – Rafael May 14 at 15:27
-1

What you can do in Gimp is use the curves tool (on each R, G & B channel) to make the color of the red square in the chart be some known RGB value. Then you measure the red in the tomato as another set of RGB (or several...). How much "red" is that color is subject to debate, possibly a mix of Hue and Saturation.

1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.