#include <processor.h>
Inheritance diagram for EMAN::NormalizeMaxMinProcessor:
Public Member Functions | |
string | get_name () const |
Get the processor's name. | |
string | get_desc () const |
Get the descrition of this specific processor. | |
Static Public Member Functions | |
static Processor * | NEW () |
Static Public Attributes | |
static const string | NAME = "normalize.maxmin" |
Protected Member Functions | |
float | calc_sigma (EMData *image) const |
float | calc_mean (EMData *image) const |
mean -> (maxval-minval)/2; std dev = (maxval+minval)/2;
Definition at line 4222 of file processor.h.
float NormalizeMaxMinProcessor::calc_mean | ( | EMData * | image | ) | const [protected, virtual] |
Implements EMAN::NormalizeProcessor.
Definition at line 3632 of file processor.cpp.
References EMAN::EMData::get_attr(), and LOGWARN.
03633 { 03634 if (!image) { 03635 LOGWARN("NULL Image"); 03636 return 0; 03637 } 03638 float maxval = image->get_attr("maximum"); 03639 float minval = image->get_attr("minimum"); 03640 return (maxval - minval) / 2; 03641 }
float NormalizeMaxMinProcessor::calc_sigma | ( | EMData * | image | ) | const [protected, virtual] |
Reimplemented from EMAN::NormalizeProcessor.
Definition at line 3621 of file processor.cpp.
References EMAN::EMData::get_attr(), and LOGWARN.
03622 { 03623 if (!image) { 03624 LOGWARN("NULL Image"); 03625 return 0; 03626 } 03627 float maxval = image->get_attr("maximum"); 03628 float minval = image->get_attr("minimum"); 03629 return (maxval + minval) / 2; 03630 }
string EMAN::NormalizeMaxMinProcessor::get_desc | ( | ) | const [inline, virtual] |
Get the descrition of this specific processor.
This function must be overwritten by a subclass.
Implements EMAN::Processor.
Definition at line 4235 of file processor.h.
04236 { 04237 return "normalizes an image. mean -> (maxval-minval)/2; std dev = (maxval+minval)/2;"; 04238 }
string EMAN::NormalizeMaxMinProcessor::get_name | ( | ) | const [inline, virtual] |
Get the processor's name.
Each processor is identified by a unique name.
Implements EMAN::Processor.
Definition at line 4225 of file processor.h.
References NAME.
04226 { 04227 return NAME; 04228 }
static Processor* EMAN::NormalizeMaxMinProcessor::NEW | ( | ) | [inline, static] |
Definition at line 4230 of file processor.h.
04231 { 04232 return new NormalizeMaxMinProcessor(); 04233 }
const string NormalizeMaxMinProcessor::NAME = "normalize.maxmin" [static] |