[Radiance-general] computing the standard deviation of pixels above zero

Greg Ward gregoryjward at gmail.com
Mon Jun 14 21:54:50 PDT 2010


Hi Kyle,

Between your toflt and total put the following:

... | toflt | rcalc -if -of -e '$1=$1;cond=1e-6-$1' | total -if ...

-Greg

> From: kkonis at berkeley.edu
> Date: June 14, 2010 2:58:11 PM PDT
>
> I have an HDR image that was generated by combining the original HDR  
> with
> an equally sized bitmap image to mask out an area within the image for
> analysis. I have a script that enables the average luminance of the  
> masked
> area to be computed via (from the below script):
>
> taskavg=`thpic -o $inp $tdir/$task.pic | toflt | total -if`
>
> *I would like to compute the standard deviation of only the non-zero
> pixels and am unsure how to do this.
>
> the program "total" has a number of options to calculate the mean,  
> max,
> min, RMS,etc, but i need to filter out all of the zero'ed pixels  
> before/as
> I pass the pixel data to it.
>
> Any suggestions would be appreciated. I have put a sample image  
> (out.hdr)
> as well as the script, mask, and orig image (example.hdr) in the  
> following
> directory online
>
> https://gaia.lbl.gov/people/kskonis/share/TEMP/masks_lab/
>
> best,
>
> Kyle Konis



More information about the Radiance-general mailing list