Average luminance of an area and pfsstat issues

76 views
Skip to first unread message

Kate Shaw

unread,
Jun 14, 2015, 5:19:21 AM6/14/15
to pfst...@googlegroups.com
Hello,

I am making HDR images (in .exr format) using pfstools 2.0.1. I am wanting to find average luminance values for specific areas in my image. Is there a way to select an area in pfsview? I was reading through the manual pages and found the entry for pfsstat which looks close to what I need. Is this the command I need? If it is then I have a problem because I can not get pfsstat to execute. When I use it in terminal I get "pfsstat: command not found". I added it to my $PATH but I get the same result. If I go directly to the pfsstat exc file in my src/octave folder and open it I get the following output in terminal:

-bash: /Users/kate/.bash_profile: line 10: unexpected EOF while looking for matching `"'

-bash: /Users/kate/.bash_profile: line 11: syntax error: unexpected end of file

/Users/kate/pfstools/src/octave/pfsstat ; exit;

kateshasMacBook:~ kate$ /Users/kate/pfstools/src/octave/pfsstat ; exit;

-bash: /Users/kate/pfstools/src/octave/pfsstat: /usr/bin/octave: bad interpreter: No such file or directory

logout


[Process completed]


Can any one help me?


Kate

Rafal

unread,
Jun 14, 2015, 5:54:20 PM6/14/15
to pfst...@googlegroups.com, 90ka...@gmail.com
Hi Kate,

There is a number of issues:

* pfstats has not been well maintained and was actually not installed in pfstools 2.0.1. This is only fixed in the git repository (not .tar.gz release). You would need to get and compile the very latest pfstools from git. 

* There seems to be an issue with your .bash_profile file in line 10.

* The message "/usr/bin/octave: bad interpreter" suggests that you may not have octave installed. You may also need a few extra octave packages (image, signal, etc.)

* You need to set path in .octaverc

setpath( '/usr/local/share/pfstools/octave' );

I hope it helps.

Rafal

Kate Shaw

unread,
Jun 16, 2015, 10:31:45 PM6/16/15
to pfst...@googlegroups.com, 90ka...@gmail.com
Thanks for your response Rafal.
I'm looking on git for the latest pfstools version. The only thing I can find is pfstools.spec and some .patch files.  The link to the page I'm looking at is https://github.com/pld-linux/pfstools. Is this what you mean? Pfstools.spec is just a page of text/code. I'm not sure what to do with it. 

Kate

Rafal

unread,
Jun 17, 2015, 6:42:06 AM6/17/15
to pfst...@googlegroups.com, 90ka...@gmail.com

On Wednesday, 17 June 2015 03:31:45 UTC+1, Kate Shaw wrote:
Thanks for your response Rafal.
I'm looking on git for the latest pfstools version. The only thing I can find is pfstools.spec and some .patch files.  The link to the page I'm looking at is https://github.com/pld-linux/pfstools. Is this what you mean? Pfstools.spec is just a page of text/code. I'm not sure what to do with it. 

Please use the following repository:



Kate Shaw

unread,
Jun 19, 2015, 11:39:09 PM6/19/15
to pfst...@googlegroups.com, 90ka...@gmail.com

Thanks Rafal. 

I have downloaded the version of pfstools from the link you gave me. I'm in the middle of doing my cmake && make which completed fine. I've noticed, however, that in the list of targets built, pfsstat is not included. I have installed octave, octave-image, octave-signal, octave-specfun and octave-control through MacPorts. Am I missing something important or should I continue to make install?

Kate

Rafal

unread,
Jun 20, 2015, 5:47:21 AM6/20/15
to pfst...@googlegroups.com, 90ka...@gmail.com
You need to include the package that includes "mkoctfile" (I am not sure which one is that in MacPorts). mkoctfile needs to be in the path.

Rafal

Kate Shaw

unread,
Jul 1, 2015, 7:34:21 PM7/1/15
to pfst...@googlegroups.com, 90ka...@gmail.com
Ok so I do have the mkoctfile:

$ which mkoctfile

/opt/local/bin/mkoctfile


It even says mkoctfile found in my cmake. However I'm still not getting pfsstat in my make:


$ make

[  3%] Built target pfs

[  4%] Built target pfsinexr

[  5%] Built target pfsinimgmagick

[  6%] Built target pfsinpfm

[  8%] Built target pfsinrgbe

[ 10%] Built target pfsintiff

[ 11%] Built target pfsoutexr

[ 12%] Built target pfsoutimgmagick

[ 13%] Built target pfsoutpfm

[ 15%] Built target pfsoutrgbe

[ 17%] Built target pfsouttiff

[ 18%] Built target pfsabsolute

[ 20%] Built target pfscat

[ 21%] Built target pfsclamp

[ 22%] Built target pfscolortransform

[ 23%] Built target pfscut

[ 25%] Built target pfsdisplayfunction

[ 26%] Built target pfsextractchannels

[ 27%] Built target pfsflip

[ 28%] Built target pfsgamma

[ 29%] Built target pfspad

[ 30%] Built target pfspanoramic

[ 31%] Built target pfsretime

[ 32%] Built target pfsrotate

[ 33%] Built target pfssize

[ 34%] Built target pfstag

[ 36%] Built target pfsouthdrhtml

[ 48%] Built target pfsview

[ 54%] Built target pfsglview

[ 55%] Built target pfsclose.cpp

[ 56%] Built target pfsget.cpp

[ 57%] Built target pfsopen.cpp

[ 58%] Built target pfsput.cpp

[ 60%] Built target pfsread.cpp

[ 61%] Built target pfstransform_colorspace.cpp

[ 62%] Built target pfswrite.cpp

[ 64%] Built target pfstmo_drago03

[ 66%] Built target pfstmo_mantiuk06

[ 69%] Built target pfstmo_reinhard02

[ 71%] Built target pfstmo_reinhard05

[ 73%] Built target pfstmo_pattanaik00

[ 76%] Built target pfstmo_fattal02

[ 81%] Built target pfstmo_durand02

[ 83%] Built target pfstmo_mai11

[ 86%] Built target pfstmo_ferradans11

[ 93%] Built target pfstmo_mantiuk08

[100%] Built target pfshdrcalibrate


The only thing that I haven't done that you suggested is setting a path in .octaverc. Is this my problem? If it is could you please explain what this is how to do it. I don't want to set the wrong path incase the one you provided (/usr/local/share/pfstools/octave) is different to what's on my computer. 


Kate Shaw

unread,
Jul 27, 2015, 4:18:16 AM7/27/15
to pfstools, man...@gmail.com

Hello again,
I think I've made progress. I added the pfstools/src/octave directory to the octave path. I installed pfstools and now when I go

$ which pfsstat

I get :

/usr/local/bin/pfsstat

So it seems its has installed it fine. However, I'm getting an error when I'm trying to use it. 

Kate$ pfsin IMG_0709.JPG | pfsstat

error: 'pfsopen' undefined near line 28 column 7

error: called from:

error:   /usr/local/bin/pfsstat at line 28, column 5


Does anyone know how to fix this? 


Thanks,

Kate

Reply all
Reply to author
Forward
0 new messages