X-Ray, or rather IR, vision

Here everybody can post his problems with PhotoLine
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: X-Ray, or rather IR, vision

Beitrag von cathodeRay »

I agree there is some rather elegant about using the IR channel, if we can make it work, hence the main reason for starting this thread. The mystery shadow above the dog's back absolutely does look like an artefact in the processed crop, but in the full original slide it also makes sense as a deeper shadow from what looks like a tree, a full shadow on what is otherwise more of a dappled shadow. It's full long axis is also exactly parallel to the shadow from the dog's hind legs. You can just make out a sense of it in the unprocessed crop as a swathe across the image. It gets accentuated in standard processing, but the interesting thing is the IR scan doesn't see it (bizarre, I know), so any reworkings based on the IR scan don't have it.

I did have a look at the individual channels but they don't really stand out one from another in any significant way. The histogram for the background is that L shape I mentioned, with the red peak just a little to the right of the green and blue peaks. Moving the cursor/eyedropper over the area gives as we might expect very flat RGB values in the teens, with red consistently slightly ahead. The full image has over 4 million individual colours in it, but in even quite a large crop of the background area this falls to around 333,000 colours. We are dealing with significantly anaemic data here.

Unfortunately, I strongly suspect the owner of the slide (I'm doing it for a friend) would very understandably prefer that I don't put the full slide online, because in a nutshell we don't have the consent of the two people in the photo. I may be a bit over-scrupulous about this, but probably better to err on the side of scruples over this sort of thing.

The original scan was saved as an uncompressed 16 bit tiff, around 40MB for the RGB image, 13MB for the IR channel (I'm using 2400dpi as these are not exactly tripod mounted perfect exposures in ideal light, and so in my book there is not need to go above 2400dpi). I will see whether I can upload 16 bit versions somehow without blowing the max attachment file size here which I cannot for the life of me remember what it is right now...

cR
Benutzeravatar
photoken
Mitglied
Beiträge: 2162
Registriert: Sa 28 Sep 2013 01:25

Re: X-Ray, or rather IR, vision

Beitrag von photoken »

cathodeRay hat geschrieben:I did have a look at the individual channels but they don't really stand out one from another in any significant way. The histogram for the background is that L shape I mentioned, with the red peak just a little to the right of the green and blue peaks. Moving the cursor/eyedropper over the area gives as we might expect very flat RGB values in the teens, with red consistently slightly ahead. The full image has over 4 million individual colours in it, but in even quite a large crop of the background area this falls to around 333,000 colours. We are dealing with significantly anaemic data here.
I understand. It was just a thought....

Another option would be to install the FITS Liberator program that I mentioned in the astrophotography posting. I don't have it on this new computer, so I don't know if it can open TIFs, but if it can open them it has some very sophisticated options for expanding "hidden" values that are buried in the extreme portions of the luminances. Might be worth a shot.

Edit:
I installed the FITS Liberator to test, and unfortunately it only opens FITS images. :(
Ken
Yes, I think it can be eeeeeasily done....
Just take everything out on Highway 61.
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: X-Ray, or rather IR, vision

Beitrag von cathodeRay »

I haven't tried FITS Liberator yet but I have been trying out some of the more esoteric colour matching methods brought to my notice by Prof Google. These tend to be scripts of some form, typically python, so some setting up is needed (bit of an understatement, that). However, preliminary results are at least to me interesting, in that they show potential signs of achieving the Holy Grail of palette injection. Most of them, including the two below, explicitly aim to transfer the colours from a donor image to a target image. The first (as I understand it) does histogram matching in the [Y]CbCr colour space, the second converts to Lab, does some voodoo, and the converts back again. In both cases the donor (source) image was the bottom half of the original scan image, so the bottom half is donating to itself and the upper half.
scan.jpg
scan_new.jpg
scan_transfer.jpg
Neither are perfect, but they do seems to me to show subtle adjustments in the right direction, as well as some less favourable changes. The second (Lab based) one seems specially promising, with suble but helpful changes, and I'm trying see if I can get my head round the maths to see if I can tweak the output (the script is an editable python script). The second is built into G'MIC and so less amenable to tinkering.

Links to relevant websites:

[Y]CbCr HG matching: https://secure.flickr.com/groups/gmic/d ... 453465326/

Lab math based: http://www.pyimagesearch.com/2014/06/30 ... er-images/

BTB if anyone want to follow through on these, and needs to install openCV to do so, don't use the full openCV, it's the size of a block of flats, instead just download the openCV-python bit (google is your friend)...

cathodeRay

PS I do appreciate that the above is a sort of auto-transfusion, but as a 'proof of concept' it has great promise. Neither method requires the donor image to be the same size as the recipient, so there is the potential to find a decent swatch from any image as the donor - the possibilities seem limitless...

PPS Ken - just noticed your edit about FITS - oh well, it was worth a try.
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
Benutzeravatar
photoken
Mitglied
Beiträge: 2162
Registriert: Sa 28 Sep 2013 01:25

Re: X-Ray, or rather IR, vision

Beitrag von photoken »

I thought that the field of astrophotography might have some interesting solutions, so I searched for "astrophotography image processing software" and the only software of interest is the StarTools thingy:
http://www.startools.org/

It's only available as an alpha version, with no clue as to WTF the price is/will be, and the alpha does not allow saving, but here's a quick result (screen capture):
DIA StarTools.jpg
Intriguing, no? :wink:

Edit:
OK, I found their purchasing page -- the price is $50 (US). That's really too expensive for me....
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
Ken
Yes, I think it can be eeeeeasily done....
Just take everything out on Highway 61.
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: X-Ray, or rather IR, vision

Beitrag von cathodeRay »

Ken - intriguing? Yes! The startools website is curious, lots of buzz words, is it a black box (hole?) SW or not? I'm not quite sure I understand what data-mining means in relation to image processing. Nor is it clear where they are from. Sweden? Australia? I'm never really comfortable with companies/organisations that want you to part with your money but won't reveal who they are/where they are. It's all very well saying you are on a mission to make astro-photography more accessible and affordable... But I agree the price is stuck somewhere in the middle, and probably too much for a program that many will only use on a (very) occasional basis.

I wonder if one of the main things startools brings to the mix is deconvolution? I am a few light years away from understanding the maths behind deconvolution, but I have seen it produce impressive, sometimes almost magical results, though equally their are times when it fails miserably. I think it may be that it needs the right sort of initial conditions to get something useful.

While we're on cross-disciplinary thinking, I wonder if medical image processing technology has anything to offer? Every now and then I come across a site that mentions things like making X-Rays (or rather the radiographs they produce) more easily read, or bringing out the detail in histological slides.

Talking of which, I do have a copy of 4N6Site's colour deconvolution plugin (modest donationware, well worth it because sometimes it achieves magic), and it mentions histology among the examples, but on this image it struggled. Sometimes a bit more detail appeared in the shadows, but never enough to be useful (but don't be put off from trying the plugin on other problem images, when it does work, it's brilliant).

I'm still inclined to focus on the colour donor/recipient approach, because if it can be made to work well enough, then it is a generic approach which could be very useful in all sorts of common situations: fading (the yacht), under-exposure (as here), both very common problems.

cR
Benutzeravatar
photoken
Mitglied
Beiträge: 2162
Registriert: Sa 28 Sep 2013 01:25

Re: X-Ray, or rather IR, vision

Beitrag von photoken »

I found a new approach to this problem that dovetails nicely with my request for an enhanced HDR feature (http://www.pl32.com/forum3/viewtopic.ph ... 497#p41203).

There is a free online conversion site:
http://www.files-conversion.com/image/fits
that will convert many types of image files to the FITS image format.

I converted your cropped image to FITS, and then opened it in FITS Liberator. This technique seemed to have some potential, but there were way too many JPG artifacts to do a decent test. I'd be interested in hearing what you think, if you have the time to experiment with your original 16-bit TIFs.

Note: That image conversion site will always save your converted image with a "html" extension. No problem -- simply rename the saved file to <whatever>.fits, and FITS Liberator will open it just fine. The channels come into FITS Liberator as what it calls "planes". After modifying a "plane", you can save it as a TIF (B&W), and use one of the techniques described here:
http://www.pl32.com/forum3/viewtopic.ph ... 966#p36796
to combine the B&W images into a colour image.
Ken
Yes, I think it can be eeeeeasily done....
Just take everything out on Highway 61.
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: X-Ray, or rather IR, vision

Beitrag von cathodeRay »

Ken - thanks, looks very interesting and definitely worth pursuing. I have been rather bogged down with my attempts to generate saturation and other input/output scatter plots (as in the other recent thread), which are a shameless but so far fruitless foray into reverse engineering successful image enhancements so that the same techniques can then be applied to other otherwise deficient images to improve them. I've also been attempting to get an industrial strength but quick to use way of getting rid of IR cleaning artefacts introduced by Vuescan - for some reason it has recently rather lost it's usual sure-footedness, and has taken to leaving ghostly halos, and High Pass/High Frequency overlay blend methods only go so far as the artefacts are both darker and lighter than their correct surroundings. But the goal of being able reliably to inject realistic colour back into an image that has for whatever reason lost it is such a worthwhile one that I will not be letting it go any time soon.

cR