parameters in pfstmo_reinhard02

35 views
Skip to first unread message

Jack

unread,
May 5, 2008, 5:23:21 PM5/5/08
to pfstools
Can we set any parameter for pfstmo_reinhard02 (like key value and
white point)? Or they are automatically set by the program using
Reidhard's method (Parameter Estimation for Photographic Tone
Reproduction)?

Is pfstmo_reinhard02 implemented for global mapping or local? (It
seems to me that it is global.) How can I get a local tone-map?

Rafal Mantiuk

unread,
May 5, 2008, 6:45:53 PM5/5/08
to pfst...@googlegroups.com
Hi,

> Can we set any parameter for pfstmo_reinhard02 (like key value and
> white point)? Or they are automatically set by the program using
> Reidhard's method (Parameter Estimation for Photographic Tone
> Reproduction)?

If no parameters are given, Reidhard's method is used to estimate
them. Check "man pfstmo_reinhard0" for the command line options.

> Is pfstmo_reinhard02 implemented for global mapping or local? (It
> seems to me that it is global.) How can I get a local tone-map?

It's both global and local method, but you may need to set command
line option (--scales) to switch to the local method.

Cheers,

Rafal

Jack

unread,
May 6, 2008, 2:20:56 AM5/6/08
to pfstools
Thanks Rafal.

I tried "man pfstmo_reinhard02", but it keeps showing "No manual entry
for pfstmo_reinhard02 / See 'man 7 undocumented' for help when manual
pages are not available." Does this mean I didn't install some
document-related functions? How can I deal with that?

BR,

Jack

Rafal Mantiuk

unread,
May 6, 2008, 12:09:55 PM5/6/08
to pfst...@googlegroups.com
On Mon, May 5, 2008 at 11:20 PM, Jack <jack.mak....@gmail.com> wrote:
> I tried "man pfstmo_reinhard02", but it keeps showing "No manual entry
> for pfstmo_reinhard02 / See 'man 7 undocumented' for help when manual
> pages are not available." Does this mean I didn't install some
> document-related functions? How can I deal with that?

All manual pages should be installed after you run "make install". But
you may still need to set the shell variable MANPATH to point to where
the manual pages are install (usually /usr/local/man).

You can also go the source directory and run "man ./command.1"

Cheers,

Rafal

Jack

unread,
May 12, 2008, 5:34:59 PM5/12/08
to pfstools
Thanks..Rafal.

On May 6, 9:09 am, "Rafal Mantiuk" <mant...@googlemail.com> wrote:

Vasco Nascimento

unread,
Jan 29, 2013, 10:13:00 AM1/29/13
to pfst...@googlegroups.com

Hi there

I've been using the pfstools software for linux for some time now, and i have a question for you.

I have searched the internet for this information and i stumbled upon this mail from you:

"Hi,

>  Can we set any parameter for pfstmo_reinhard02 (like key value and
>  white point)? Or they are automatically set by the program using
>  Reidhard's method (Parameter Estimation for Photographic Tone
>  Reproduction)?

If no parameters are given, Reidhard's method is used to estimate


them. Check "man pfstmo_reinhard0" for the command line options.

>  Is pfstmo_reinhard02 implemented for global mapping or local? (It

>  seems to me that it is global.) How can I get a local tone-map?

It's both global and local method, but you may need to set command


line option (--scales) to switch to the local method.

Cheers,

Rafal"


My question is simple. When you use the tone mapping operator from Reinhard02, with the default settings, that is, ' (...).pfs|pfstmo_reinhard02|pfsout (...).bmp', this algorithm implements the global and local tone mapping, as you said in the mail i have quoted? I need to know, if for, my 10 bit initial image, this algorithm, with the default parameters, preforms both the initial luminance mapping and Automatic dodging-and-burning, as said in the paper: "Photographic Tone Reproduction for Digital Images" by Reinhard et al.

Best regards and thanks in advance for your time.

Vasco Nascimento

Rafal

unread,
Jan 29, 2013, 10:28:58 AM1/29/13
to pfst...@googlegroups.com


On Tuesday, 29 January 2013 15:13:00 UTC, Vasco Nascimento wrote:
My question is simple. When you use the tone mapping operator from Reinhard02, with the default settings, that is, ' (...).pfs|pfstmo_reinhard02|pfsout (...).bmp', this algorithm implements the global and local tone mapping, as you said in the mail i have quoted?


Now I noticed a mistake in the documentation. This operator requires gamma correction so you should be running it:

pfsin ... | pfstmo_reinhard02 | pfsgamma -g 2.2 | pfsout ...

 
I need to know, if for, my 10 bit initial image, this algorithm, with the default parameters, preforms both the initial luminance mapping and Automatic dodging-and-burning, as said in the paper: "Photographic Tone Reproduction for Digital Images" by Reinhard et al.

Dodging-and-burning is done only if you pass "-s" parameter. 
 
Best,

Rafal

Vasco Nascimento

unread,
Jan 29, 2013, 10:38:03 AM1/29/13
to pfst...@googlegroups.com
So for what i understand from your reply, i can't use the tone mapping operator from Reinhard02 without using gamma correction? Even if the gamma correction introduces adjustments that i don't want them?

And without specifying the parameter '-s' in the command line the operator just makes the initial luminance mapping skipping up the dodging-and -burning process. Correct?


Best regards,

Vasco Nascimento
2013/1/29 Rafal <man...@gmail.com>

--
You received this message because you are subscribed to the Google Groups "pfstools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pfstools+u...@googlegroups.com.
To post to this group, send email to pfst...@googlegroups.com.
Visit this group at http://groups.google.com/group/pfstools?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Rafal

unread,
Jan 29, 2013, 10:50:12 AM1/29/13
to pfst...@googlegroups.com


On Tuesday, January 29, 2013 3:38:03 PM UTC, Vasco Nascimento wrote:
So for what i understand from your reply, i can't use the tone mapping operator from Reinhard02 without using gamma correction? Even if the gamma correction introduces adjustments that i don't want them?

If you want to follow the paper, you should use gamma. But if you just want to generate good looking images, it is up to you to tweak the gamma parameter. "gamma -g 1.0" will not change anything, increasing gamma decreases contrast. 

And without specifying the parameter '-s' in the command line the operator just makes the initial luminance mapping skipping up the dodging-and -burning process. Correct?

Yes.
 
BTW. The operator expects HDR or linear RGB images as input. I am not sure what your 10-bit images are. If they are RAW images, they should be fine. 

Rafal

Vasco Nascimento

unread,
Jan 29, 2013, 10:58:32 AM1/29/13
to pfst...@googlegroups.com
Ok. Thank you very much for the clarifications.

Best regards,

Vasco Nascimento

2013/1/29 Rafal <man...@gmail.com>



Rafal

--

Vasco Nascimento

unread,
Jan 31, 2013, 10:12:28 AM1/31/13
to pfst...@googlegroups.com
Sorry to bother you again Rafal, but i am really having a hard time using scales with Reinhard tone mapping algorithm. I am using the nex command line, with some variations in the parameters, but the end result shows always like the colors lost some of their strenght. The image become more bright in all the image, yes, but it feals like a ghost of its original image. Feels like the scales introduce a global operation and not a local one as presented in the paper.. Not really the result i was looking for... Am i doing something wrong?

 pfsin ...pfs|pfstmo_reinhard02 -s -k 0.36|pfsgamma -g 1.8| pfsout ....bmp


Best regars and thank you for your time.

Vasco Nascimento

2013/1/29 Vasco Nascimento <nascimen...@gmail.com>

Rafal

unread,
Feb 1, 2013, 4:22:58 PM2/1/13
to pfst...@googlegroups.com
On Thursday, January 31, 2013 3:12:28 PM UTC, Vasco Nascimento wrote:
Sorry to bother you again Rafal, but i am really having a hard time using scales with Reinhard tone mapping algorithm. I am using the nex command line, with some variations in the parameters, but the end result shows always like the colors lost some of their strenght. The image become more bright in all the image, yes, but it feals like a ghost of its original image. Feels like the scales introduce a global operation and not a local one as presented in the paper.. Not really the result i was looking for... Am i doing something wrong?

 pfsin ...pfs|pfstmo_reinhard02 -s -k 0.36|pfsgamma -g 1.8| pfsout ....bmp

Well, I tried it on a few images and they look OK. Perhaps you could post the results that look wrong.

It could be that this operator requires some tweaking of parameters to get good results. Few operators give acceptable results with default parameters.

I believe this operator uses original author's code, which we integrated with pfstools.

Rafal

Vasco Nascimento

unread,
Feb 1, 2013, 5:34:36 PM2/1/13
to pfst...@googlegroups.com

Hi there.

In the attatchments, the first picture is the original one, the second one is using only the luminance mapping, with the gamma parameter with the value 1.2, and finally the third one is using the parameters next parameters:

pfsin NM227.pfs|pfstmo_reinhard02 -s -k 0.36|pfsgamma -g 1.8| pfsout NM227_new.bmp

If you need the initial pfs file to test, tell me and i will send you.

Thanks in advance.

Vasco Nascimento



2013/2/1 Rafal <man...@gmail.com>

Rafal

NM227.jpg
NM227_reinhard02_g1.2.jpg
NM227_new.jpg

Rafal

unread,
Feb 2, 2013, 7:45:48 PM2/2/13
to pfst...@googlegroups.com
On Friday, 1 February 2013 22:34:36 UTC, Vasco Nascimento wrote:

Hi there.

In the attatchments, the first picture is the original one, the second one is using only the luminance mapping, with the gamma parameter with the value 1.2, and finally the third one is using the parameters next parameters:

pfsin NM227.pfs|pfstmo_reinhard02 -s -k 0.36|pfsgamma -g 1.8| pfsout NM227_new.bmp


Judging from the images, the source image is most probably already gamma corrected (not HDR). The noise suggest that it is only one exposure and and the dark levels are too bright for a non-gamma corrected (linear) image. The reflective print is unlikely to have contrast greater than 100:1, so there could be little point in tone-mapping that image.

The tone-mapping operators are meant to work with HDR images (.exr, .hdr), generated with pfshdrcalibrate or other software. They will not produce good results if run on standard (gamma corrected, sRGB) images.

Rafal

Vasco Nascimento

unread,
Feb 3, 2013, 10:40:41 AM2/3/13
to pfst...@googlegroups.com
Hi Rafal, Thanks for the reply. The original images are from sequences recorded in the yuv10 format and the converted to yuv and then, divided  into pfs file, changing from the yuv colorspace to RGB and the to XYZ, using software that i have implemented. They were recorded in Native 10 bit 4:2:2 on DVS HDStationPlus Discrecorder by SVT television.

Thanks again.

Vasco Nascimento

2013/2/3 Rafal <man...@gmail.com>

Rafal

Reply all
Reply to author
Forward
0 new messages