IPB

Welcome Guest ( Log In | Register )

5 Pages V   1 2 3 > »   
Reply to this topicStart new topic
Processing VIMS cubes, An attempt at "true" color
ugordan
post Sep 10 2006, 07:51 PM
Post #1


Senior Member
****

Group: Members
Posts: 3648
Joined: 1-October 05
From: Croatia
Member No.: 523



Right, a suggestion I made here in another topic made me wonder why not try that myself. A bunch of data was sitting on the PDS, after all. After a hassle figuring out just how the image cubes are organized and trying to read them, finally I was able to produce some results. This is all very rough work, can be considered first-iteration only and not particularly accurate.
Basically, I used the cubes to extract the visible spectrum in the 380-780 nanometer range which was then input to color matching code I found here by Andrew T. Young.
The code integrates over 40 10-nm steps to produce CIE XYZ color components. I then converted these to RGB values.

I'm aware of at least three inaccuracies in my code as of yet: one is the above sampled code apparently uses Illuminant C as the light source, not true solar spectra so the color turns out bluish (has a temp. of 9300 K instead of 6500 K, AFAIK). I tried to compensate at the moment by changing the final RGB white balance, but this is probably an inaccurate way to go. Another inaccuracy is I don't do bias removal from the cubes. This likely affects the outcome. Also, I don't use the precise wavelengths the code requires, but use the closest one in the cube. I intend to fix this by interpolating between nearest wavelengths.

All images are enlarged 4x.

Attached Image
Attached Image
Attached Image

The leftmost image is a 4-cube mosaic. The colors in all four frames turned out identical which gives me at least some confidence. The image in the middle shows Dione's disc creeping in front of Saturn. Dione's disc appears elongated probably because as the lines were readout, it moved considerably in its orbit. The rightmost image shows a very overexposed Saturn image, the part below the ring shadows got overexposed. From what I've seen browsing through the PDS, a lot of the cubes are badly overexposed at some wavelengths.

Here's a couple of Jupiter images. I'm not very satisfied with them as they seem to look somewhat greenish, but overall the color looks believeable:
Attached Image

Attached Image


Lastly, two Titan composites. They turned out way more reddish than I thought they would.
Attached Image
Attached Image


It'll be interesting to see how much the results will change once I do a more proper processing pipeline working.


--------------------
Go to the top of the page
 
+Quote Post
Malmer
post Sep 12 2006, 09:48 PM
Post #2


Member
***

Group: Members
Posts: 241
Joined: 22-August 05
From: Stockholm Sweden
Member No.: 468



its a really great "realitycheck" for the ordinary ISS images.
Go to the top of the page
 
+Quote Post
dilo
post Sep 12 2006, 10:21 PM
Post #3


Senior Member
****

Group: Members
Posts: 2492
Joined: 15-January 05
From: center Italy
Member No.: 150



Very nice work, gordan... now we see the colors!
Only one observation: in the second 4-cube image, you say that dark, elongated feature in front of Saturn is Dione's disc. To me, is evident we are seeing the Dione shadow projected on the Saturn atmosphere: this would easily explain why is so dark and with an elongated/deformed shape... do not you agree?


--------------------
I always think before posting! - Marco -
Go to the top of the page
 
+Quote Post
ugordan
post Sep 13 2006, 06:56 AM
Post #4


Senior Member
****

Group: Members
Posts: 3648
Joined: 1-October 05
From: Croatia
Member No.: 523



QUOTE (dilo @ Sep 12 2006, 11:21 PM) *
To me, is evident we are seeing the Dione shadow projected on the Saturn atmosphere: this would easily explain why is so dark and with an elongated/deformed shape... do not you agree?

VIMS cube : v1492290669_1.qub, time : 2005-04-15 20:44:12 thru 2005-04-15 20:49:59

Solar System Simulator view here.
There is no way any but the closest ring moons could have cast a shadow onto Saturn, it was still far from autumn equinox at the time.
BTW, all images except the first one are single cubes with a 64x64 pixel spatial resolution.


--------------------
Go to the top of the page
 
+Quote Post
ugordan
post Sep 13 2006, 08:56 AM
Post #5


Senior Member
****

Group: Members
Posts: 3648
Joined: 1-October 05
From: Croatia
Member No.: 523



QUOTE (Malmer @ Sep 12 2006, 10:48 PM) *
its a really great "realitycheck" for the ordinary ISS images.

Indeed. I was surprised how close to official releases the Saturn and Jupiter images turned out. Frankly, I was a bit skeptical about color balances in some of CICLOPS releases, but these images (if they turn out more or less correct) prove me wrong. There are images that do look strangely color-balanced such as this recent Jupiter map and especially the earlier Jupiter flyby releases, but this rendered portrait is probably the closest to the left Jupiter VIMS image, especially when taking into consideration I increased the gamma in my images which reduced the contrast and washed out the colors a bit, but making them a bit more realistic IMHO.

Saturn also turned out remarkably similar to for example this composite and this higher phase view, again only differing in saturation and brightness. Then again, there's this image...

The most notable exception I can see is Titan which turns out much more yellow than red in ISS releases.


--------------------
Go to the top of the page
 
+Quote Post
CAP-Team
post Sep 13 2006, 02:16 PM
Post #6


Member
***

Group: Members
Posts: 146
Joined: 23-August 06
From: Vriezenveen, Netherlands
Member No.: 1067



It looks as if the colors match Voyager's colors a lot more. The images of Titan look like the images Voyager took.
Go to the top of the page
 
+Quote Post
Malmer
post Sep 13 2006, 02:49 PM
Post #7


Member
***

Group: Members
Posts: 241
Joined: 22-August 05
From: Stockholm Sweden
Member No.: 468



QUOTE (ugordan @ Sep 10 2006, 09:51 PM) *
I'm aware of at least three inaccuracies in my code as of yet: one is the above sampled code apparently uses Illuminant C as the light source, not true solar spectra so the color turns out bluish (has a temp. of 9300 K instead of 6500 K, AFAIK). I tried to compensate at the moment by changing the final RGB white balance, but this is probably an inaccurate way to go. Another inaccuracy is I don't do bias removal from the cubes. This likely affects the outcome. Also, I don't use the precise wavelengths the code requires, but use the closest one in the cube. I intend to fix this by interpolating between nearest wavelengths.


Another question you might ask yourself is what reference white one should have? Should one use an solar spectrum that are as seen from earth trough earths atmosphere (D65) or should one use an unfiltered solar spectra. (almost a blackbody at 5780K) check out :http://casa.colorado.edu/~ajsh/colour/Tspectrum.html

/Mattias
Go to the top of the page
 
+Quote Post
Malmer
post Sep 13 2006, 03:04 PM
Post #8


Member
***

Group: Members
Posts: 241
Joined: 22-August 05
From: Stockholm Sweden
Member No.: 468



QUOTE (ugordan @ Sep 13 2006, 10:56 AM) *
Indeed. I was surprised how close to official releases the Saturn and Jupiter images turned out. Frankly, I was a bit skeptical about color balances in some of CICLOPS releases, but these images (if they turn out more or less correct) prove me wrong. There are images that do look strangely color-balanced such as this recent Jupiter map and especially the earlier Jupiter flyby releases, but this rendered portrait is probably the closest to the left Jupiter VIMS image, especially when taking into consideration I increased the gamma in my images which reduced the contrast and washed out the colors a bit, but making them a bit more realistic IMHO.

Saturn also turned out remarkably similar to for example this composite and this higher phase view, again only differing in saturation and brightness. Then again, there's this image...

The most notable exception I can see is Titan which turns out much more yellow than red in ISS releases.



It would be cool to use VIMS to "teach" a compositing software what to do with for example 3 ISS channels in different wavelengths. Sort of like what Daniel Crotty is doing for the MER rovers. (only different "lessons" for each body in the saturnian system)

That way one could get extremly "real" colors from relatively sparse ISS spectral data.

/Mattias
Go to the top of the page
 
+Quote Post
dilo
post Sep 13 2006, 04:17 PM
Post #9


Senior Member
****

Group: Members
Posts: 2492
Joined: 15-January 05
From: center Italy
Member No.: 150



QUOTE (ugordan @ Sep 13 2006, 06:56 AM) *
There is no way any but the closest ring moons could have cast a shadow onto Saturn, it was still far from autumn equinox at the time.

Thanks ugordan, I didn't consider the inclination of Saturn equator...
By the way, your gallery is really stunning, great work!
This is a little enhancement of one of these pictures; is not intented to be realistic and I cannot compete with your colorimetric precision, my only objective was to amplify the faint Jupiter atmospheric details and Europa surface features. Hope you will enjoy...
Attached thumbnail(s)
Attached Image
 


--------------------
I always think before posting! - Marco -
Go to the top of the page
 
+Quote Post
Guest_DonPMitchell_*
post Sep 13 2006, 04:55 PM
Post #10





Guests






How do you convert XYZ to RGB? Are you making sRGB? Here's the matric for that transform, just in case:

CODE
ML_Matrix3x3 ML_RGBtoXYZ( 0.412410914897918,   0.357584565877914, 0.180453807115554,
                          0.212649390101432,   0.715169131755828, 0.0721815153956413,
                          0.0193317625671625,  0.119194857776165, 0.950390040874481);
ML_Matrix3x3 ML_XYZtoRGB( 3.24081206321716,   -1.53730821609497, -0.498586475849151,
                         -0.969243109226226,   1.87596642971038,  0.0415550582110881,
                          0.0556384064257144, -0.204007476568222, 1.05712962150573);
Go to the top of the page
 
+Quote Post
ugordan
post Sep 13 2006, 08:33 PM
Post #11


Senior Member
****

Group: Members
Posts: 3648
Joined: 1-October 05
From: Croatia
Member No.: 523



Yes, I'm using that XYZ to RGB matrix. I had to also use a scaling factor for converting Illuminant C to D65, X*0.969459, Y, Z*0.922050, prior to the RGB conversion. Only that gave me white for uniform reflectance. The RGB output is linear, I manually adjusted gamma to 1.25 in Photoshop.

I think I have bias subtraction working now (I'm still unsure if it's correct), but flatfielding seems suspicious still. There are cubes with excessive vertical banding that flat fields don't seem to touch. I'm also using a 40 point solar spectrum derived from the ISS calibration code. Somehow simply dividing by the provided solar spectra cube gives a yellowish result, when in fact it should be roughly the same. I'm now interpolating the discrete spectral wavelengths to get a nice 380-780 range.

Here are the most recent results, this time enlarged 3x:

Mimas, Dione, Rhea, Hyperion, Iapetus


Jupiter still seems too greenish somehow. The rings definitely appear to have a distinct yellow hue to them, unlike the colorful, bluish ISS releases.


--------------------
Go to the top of the page
 
+Quote Post
Guest_DonPMitchell_*
post Sep 14 2006, 04:07 AM
Post #12





Guests






Very good. Gamma 2.2 is technically what should be done, to get the image we see on the monitor to be proportional to actual scene radiance. What is the camera's radometric response function like? Are the pixel values in the VIMS file logarithmic?

As for dark current, making the background be 0 black should be right. But check the camera response. Subtracting background before or after linearization of the pixel values gives a totally different result if the camera response is nonlinear (and it probably is).

I'm not sure about the Illuminant C business. I'm not sure I understand what you did. The sRGB matrix assumes a white point of D65, which all new monitors are supposed to do. Don't think about correcting the color on the camera end, just concentrate on linearizing its response. Just plug those spectral radiance values into the XYZ integrals, convert to RGB by matrix multiple, and do gamma of 2.2. And you should see what the camera saw then!
Go to the top of the page
 
+Quote Post
ugordan
post Sep 14 2006, 07:09 AM
Post #13


Senior Member
****

Group: Members
Posts: 3648
Joined: 1-October 05
From: Croatia
Member No.: 523



The pixels are linear as far as I know, a 12 bit A/D converter is used. I think a precommanded bias value might be set to get the values out of the converter's low nonlinearity portion, or it might simply be a matter of subtracting dark current. Either way, I used the background algorithm found in the calibration package and then subtracted it.

As for Illuminant C, as I said the integration code I used produces a bluish white color if I pass it a uniform input reflectance spectra. When I used the regular CIE XYZ color matching functions, the colors turned weird. That'll need looking into. At the moment, using the supplied 40-step integration tables and using scaling factors found here, for Illum. C -> D65 got me an exact white for the test input. This can be double-checked with Mimas, Dione and Enceladus which are all very gray and sort of provide "ground truth" for the white-point.

Regarding gamma, if I set it to 2.2, the colors are all washed up and all contrast is lost. Somehow that doesn't seem right? Even with a 1.25 gamma Hyperion's reddish tint is pretty much indescernible.


--------------------
Go to the top of the page
 
+Quote Post
Malmer
post Sep 14 2006, 09:30 AM
Post #14


Member
***

Group: Members
Posts: 241
Joined: 22-August 05
From: Stockholm Sweden
Member No.: 468



QUOTE (DonPMitchell @ Sep 14 2006, 06:07 AM) *
Very good. Gamma 2.2 is technically what should be done, to get the image we see on the monitor to be proportional to actual scene radiance. What is the camera's radometric response function like? Are the pixel values in the VIMS file logarithmic?



correct me if im wrong but: sRGB does not use a 2.2 gamma. it uses its own custom crve that is reasonably close to gamma 2.2...

Attached Image


the red curve is gamma 2.2
the green is sRGB:s "gamma" curve
the blue is just linear.

The difference is mostly visible in the dark regions.

/M
Go to the top of the page
 
+Quote Post
Malmer
post Sep 14 2006, 09:43 AM
Post #15


Member
***

Group: Members
Posts: 241
Joined: 22-August 05
From: Stockholm Sweden
Member No.: 468



The pixels in the ISS images are not linearly saved. (the sensor is resonably linear but they dont save the data that way) You have to use a custom lookuptable to linearize those images. Maybe thats why you get strange results with the VIMS too. It looks to me as you are treating the raw data as linear an i dont think its saved that way. i think they save it almost logaritmically to increase dynamic range) thats why you get an image that looks as though it has alredy had an gamma correction applied to it. (i might be wrong here...)

here is the ISS data converion table.
http://pds-rings.seti.org/cassini/iss/COIS...ppf/12-8-12.pdf
Im not sure if they use something similar on the VIMS data but my guess is that they do.

ISS calibration report:
http://pds-rings.seti.org/cassini/iss/COIS...OCUMENT/REPORT/


info and software for calibrating VIMS:
http://pds-rings.seti.org/cassini/vims/

/M
Go to the top of the page
 
+Quote Post

5 Pages V   1 2 3 > » 
Reply to this topicStart new topic

 



RSS Lo-Fi Version Time is now: 28th March 2024 - 01:23 PM
RULES AND GUIDELINES
Please read the Forum Rules and Guidelines before posting.

IMAGE COPYRIGHT
Images posted on UnmannedSpaceflight.com may be copyrighted. Do not reproduce without permission. Read here for further information on space images and copyright.

OPINIONS AND MODERATION
Opinions expressed on UnmannedSpaceflight.com are those of the individual posters and do not necessarily reflect the opinions of UnmannedSpaceflight.com or The Planetary Society. The all-volunteer UnmannedSpaceflight.com moderation team is wholly independent of The Planetary Society. The Planetary Society has no influence over decisions made by the UnmannedSpaceflight.com moderators.
SUPPORT THE FORUM
Unmannedspaceflight.com is funded by the Planetary Society. Please consider supporting our work and many other projects by donating to the Society or becoming a member.