Photoshop 911
Design Center  |  DT&G Magazine  |  DT&G Forums  |  Register (Required)  |  Photoshop Tips & Tricks  |  Design Bookshelf  

Beginning in 1990, with the first version of Adobe Photoshop, DTG has published a monthly section called "Photoshop Tips & Tricks" -- Photoshop 911 became the users forum for asking specific Photoshop questions. Browse at your leisure, but to post, you must be registered.

Go Back   DTG Forums > Photoshop 911 > Emergency Room
Post Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 09-15-2008, 02:03 PM
Cil28 Cil28 is offline
Junior Member
 
Join Date: Sep 2008
Posts: 3
Default Quantitative Gradient Analysis

Hello,

I have two pictures that I want to compare. Both are of cooked tissue and i want to see the differences in the cooking techniques. I need to look at the cross sectional piece of tissue and see how the color changes, and if there is a steep or low gradient from dark color to light color back to dark color. The overall point being to see how uniformly cooked the tissue is; and what condition gives the best uniformity.

*I basically am looking for a way to plot color intensity as a function of distance across this sample; or even look at a quantitative analysis of the color gradients.

*Plotting as a function of one line would be preferred over plotting the entire image's intensity

If anyone knows any way to do this I would greatly appreciate any help provided.

edit** I am using Windows XP and the CS3 version of Photoshop

Last edited by Cil28 : 09-15-2008 at 02:07 PM.
Reply With Quote
  #2  
Old 09-16-2008, 08:51 AM
parabola parabola is offline
Junior Member
 
Join Date: Mar 2008
Posts: 27
Default

Isn't that basically the working definition of the histogram?
Reply With Quote
  #3  
Old 09-16-2008, 10:00 AM
Cil28 Cil28 is offline
Junior Member
 
Join Date: Sep 2008
Posts: 3
Default

That is quite possible and I just do not know how to use the histogram to give me the information that I need.

But, what I think I am seeing is that the histogram gives me a view of how many times a certain color appears in the image, not its transition over a length defined by me.

Let me post a photo(you can click to enlarge it), the black line is the line I want to analyze, and I want to know how quickly it changes from healthy tissue, the red, to damaged tissue, the white/pink central area. The histogram is just showing me that I have red and white in my image, not how they change across the image.

Reply With Quote
  #4  
Old 09-16-2008, 10:14 AM
tscreative tscreative is offline
Senior Member
 
Join Date: Mar 2007
Location: Maine
Posts: 457
Default

I think that if you crop the image to the area that you are concerned about and then select the Histogram it will give you what you want. The intensity of red (the high and low points) across the graph will indicate healthy tissue.

I think.
Reply With Quote
  #5  
Old 09-16-2008, 10:40 AM
admin admin is offline
Administrator
 
Join Date: Dec 2006
Posts: 299
Default

This is a tough one... and we've been asked all kinds of scientific research questions in the past... from the amount grass grows, to number of pixel growth in cancer tissue x-ray.

numbers of pixels is a pretty safe measurement -- or even a span of one color to another. However, trying to measure time or growth become very difficult -- because the photo doesn't necessarily reflect "real" quantities.

TS is on the right track, however I would be tempted to lift the row of pixels into a whole new document and read the histogram there. Each color column represents a separate color.

these essays give some of the finer points about histograms:
luminous-landscape,
cambridgeincolour.com

good luck
Reply With Quote
  #6  
Old 09-16-2008, 11:04 AM
Cil28 Cil28 is offline
Junior Member
 
Join Date: Sep 2008
Posts: 3
Default

Quote:
Originally Posted by admin
a span of one color to another.

This is exactly what I need, how would one accomplish this? The histogram under the 'view' tab seems to be for all colors, I basically need a histogram for one color (red or white); with the Y-axis (intensity) the and X-axis (position). So as I go across that black line (from left to right), I can see it start at full red, go to very little red, and then back to full red.

Some of the images are very white in the very center, and then get much more pink, the image i posted is my best image showing uniformity and I need to show that it quickly transitions from the outlying red to the white, rather than a slower transition to white indicating the area is not one uniform color.

The ideal histogram (for white color) in a uniform shape being that of a flat top curve (showing a lot of white all over the lesion and quick transition to red w/o much variation)
The ideal histogram (for white color) in a non uniform shape being a gaussian curve (showing a lot of white in the middle, less as it approaches red)

if that makes any sense.

Thanks for all the help provided so far and I have a great starting point if there is not a specific tool that can help me.

**edit** after reading those essays it appears i need some sort of color intensity plot rather than a histogram, as the histogram is looking at the levels throughout the entire image and I need a report on a single color along a position.

Last edited by Cil28 : 09-16-2008 at 11:26 AM.
Reply With Quote
  #7  
Old 09-16-2008, 12:21 PM
parabola parabola is offline
Junior Member
 
Join Date: Mar 2008
Posts: 27
Default

Quote:
Originally Posted by Cil28
**edit** after reading those essays it appears i need some sort of color intensity plot rather than a histogram, as the histogram is looking at the levels throughout the entire image and I need a report on a single color along a position.
You can specify what the histogram is focusing on see my example attached. I don't know if that's helpful.
Attached Images
File Type: jpg hist_example.jpg (87.1 KB, 5 views)
Reply With Quote
  #8  
Old 09-16-2008, 01:32 PM
parabola parabola is offline
Junior Member
 
Join Date: Mar 2008
Posts: 27
Default

after further research, I'm not sure if this is something PS can do. I found this article:
http://www3.interscience.wiley.com/j...TRY=1&SRETRY=0
But I can't read it - no access.

Last edited by parabola : 09-16-2008 at 01:52 PM.
Reply With Quote
  #9  
Old 09-17-2008, 02:09 PM
fred fred is offline
Senior Member
 
Join Date: Jan 2007
Posts: 315
Arrow

I do not know if this will help, but I just spend an hour working with your document.

Unfortunately either Adobe has done away with the "color map" function, or it's somewhere hidden where I can't find it. Haven't seen it since about version 4 or so.

Anyway here are some observations:

1) Capturing the image: I do not know if this is from some instrument or not, but to give any kind of reliable and predictable quantitative measurement, the image should be captured RAW and/or saved as a GIF. A gif file is mapped color and forces the palette to a manageable set of specific defined colors.

The sample you sent was 240 ppi JPEG which spread and mashed the true colors and introduced raster debris. This is NOT predictable as each "save" of the image will generate different results depending on the whim of the device criteria.

2) Sampling the Color: in my thumbnail attached, you can see the inherent problems with JPEG files. I went up about 8 pixels to get out of the raster debris and took a one-pixel tall selection by the width of your black line. Converting to GIF it still gave 246 individual colors -- some blues, greens, etc. So conversion is NOT an option. You'll also notice how your black line generated a lot of anti-aliasing which also will dramatically skew the results.

3) No pixel mapping function: in the "old" version of PS a pixel map would clearly indicate how many individual colors in the ramp, and allow you to "organize" those colors from light to dark -- sort of like a grayscale, if you're familiar with a grayscale card photographers and lithographers use. That would be the only reliable way to "count" the change from one shot to the next.

Histograms are pretty useless for your purposes. They are too small, impossible to extract a ramp, and for intensive purposes are merely provided in Photoshop as a "representation" rather than solid data. Besides, they're so small you'd go blind trying to select and record each and every color.

I cannot help too much beyond checking with some of the other resources like Adobe and even the Photoshop List to find other software available that will map and ramp the color.

Attached Images
File Type: gif tissue_sample.gif (32.3 KB, 2 views)
Reply With Quote
Post Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 07:04 AM.


Powered by vBulletin® Version 3.5.7
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.