ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/px/phisto.csh
Revision: 3.6
Committed: Mon Jun 29 21:03:45 2015 UTC (8 years, 10 months ago) by greg
Content type: application/x-csh
Branch: MAIN
Changes since 3.5: +6 -6 lines
Log Message:
Changed to raw data transfer for speed

File Contents

# User Rev Content
1 gwlarson 3.1 #!/bin/csh -f
2 greg 3.6 # RCSid: $Id: phisto.csh,v 3.5 2008/08/25 04:50:32 greg Exp $
3 gwlarson 3.1 #
4     # Compute foveal histogram for picture set
5     #
6 greg 3.5 set tf=`mktemp /tmp/phdat.XXXXX`
7 gwlarson 3.1 onintr quit
8     if ( $#argv == 0 ) then
9     pfilt -1 -x 128 -y 128 -p 1 \
10 greg 3.6 | pvalue -o -h -H -df -b > $tf
11 gwlarson 3.1 else
12 greg 3.5 rm -f $tf
13 gwlarson 3.1 foreach i ( $* )
14     pfilt -1 -x 128 -y 128 -p 1 $i \
15 greg 3.6 | pvalue -o -h -H -df -b >> $tf
16 gwlarson 3.1 if ( $status ) exit 1
17     end
18     endif
19 greg 3.6 set Lmin=`total -if -l $tf | rcalc -e 'L=$1*179;$1=if(L-1e-7,log10(L)-.01,-7)'`
20     set Lmax=`total -if -u $tf | rcalc -e '$1=log10($1*179)+.01'`
21     rcalc -if -e 'L=$1*179;cond=L-1e-7;$1=log10(L)' $tf \
22 gwlarson 3.1 | histo $Lmin $Lmax 100
23     quit:
24 greg 3.5 rm -f $tf