Measuring the volume of prostate cancer tumor
From Intelligent Perception
From pathologist"with an interest in the IT side of laboratory practice and well into a Pathology Informatics fellowship.
Two specific areas that interest me: 1. Calculation of tumor volume in a resected prostate gland specimen 2. Analyzing a peripheral blood smear (cell analysis) to do a count and morphological assessment."
The first picture explains what normally happens when a prostate tumor is to be evaluated. The prostate is cut into thin slices and the slices are put on pieces of glass. Next, the doctor outlines the tumor within the prostate with a marker (second image). Finally, the area of the outlined region is evaluated in each slice and the volume of the tumor is estimated.
Of course, a 3D image would be the best option for measuring a 3D object. However, the slice-by-slice approach should give you just as good accuracy. Considering the thickness of the slice (microns), the error would have to come from the 2D measurements (centimeters).
"the area that is calculated and displayed on the table is in "pixels". Can this be made to display in every day units: centimeters square/microns sq etc? Or is there a formula that I must run on the spread sheet for this?"
If a conversion formula is available, making Pixcavator display real units would take just a few minutes of programming. The problem is that there are different units and different conversion formulas in different applications. It is of course possible to have the user enter the conversion formula, like 1 pixel = 5 microns. That, however, would add another layer of complexity to the software (see customization). We will have to find a solution and for now using Excel is indeed the best option. You can insert a new column (that's E) to the right of "Size/area" (that's D). Then you enter this formula: E2 = VALUE(D2) * (5*5), assuming 1 pixel = 5 microns. You need VALUE() here because the data is in the text format. You need (5*5) here because this is area (square microns) while for the perimeter it's just 5...
Evaluating the area of the tumor with a naked eye is surely simple but the accuracy must be awful. Best one can do to improve that is to superimpose a grid over the image and count the number of squares that fall into the tumor. Then the accuracy will be proportional to the size of the square (see a picture here) but the smaller the square the more complex the manual counting will be. Using a mouse improves the accuracy but only slightly. Tracing a complex curve (with a mouse!) is hard to do with precision. And it’s not simple. What would Pixcavator provide? Well, it can’t be (at this stage) fully automatic. What it gives you is a procedure that is somewhat simple – moving sliders until you have a good fit – and quite accurate – if the fit is good. Finding a good contour won’t require formal training but probably some practice. And it still could take a few seconds per slice.
Digital image analysis is a necessity here.
I analyzed the shrunk version (615x439) of the image with Pixcavator followed by some back-of-the-envelope calculations.
The critical part of analysis is the calibration. The units are always the same. So, the unit conversion would be explicitly written in the code. (BTW, screen size and screen resolution settings don’t affect this calculation, but rather those of the camera.) For that I used the square label in the image. It is known that its side is 2.2 cm. Now, I pushed the size slider almost all the way to the right and ended up with just one object the label (green). Its area according to the table is 29,516 pixels. If we ignore the round corners (introducing some error here, unfortunately), it is a square. So 29,810 pixels = 2.2 * 2.2 = 4.84 sq cm.
Next, the tumor. The dotted line is made solid using MS Paint. The you run Pixcavator. The contour has the area of 9,491 pixels. So, it is 9,491 * 4.84 / 29,810 = 1.54 sq cm.
There is still the issue of error however. The error produced by hand drawing is estimated in the next experiment. Pixcavator evaluated the area on the outside of the curve (9,774) and on the inside (7,112). Hence the area of the curve is (9,774 – 7,112) / 9,774 = 27% of the outside of the tumor. That's the error.
It seems too high!
To verify the result, let's approach from another direction. The perimeters are 542 and 530 respectively. Then the average thickness of the line is (9840-7342)/536 = 4.7 pixels. Examination of the image confirms this number. Of course, the error can be easily cut down by making the line 1/2 thinner… To be fair the error should be divided by 2.
That brings us to the possibility of discovering the tumor within the prostate automatically. To be precise, the procedure would be semi-automatic not automatic, and it is the doctor who would make all the decisions. He chooses the contours and Pixcavator just counts pixels. What it gives you is a procedure that is somewhat simple – moving sliders until you have a good fit – and quite accurate – if the fit is good. Finding a good contour won’t require training but just a bit of practice. The last image shows that this approach isn’t unreasonable. The red contour is produced by Pixcavator.
Other image analysis examples