Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

EMAN::NormalizeMaxMinProcessor Class Reference

normalizes an image. More...

#include <processor.h>

Inheritance diagram for EMAN::NormalizeMaxMinProcessor:

Inheritance graph
[legend]
Collaboration diagram for EMAN::NormalizeMaxMinProcessor:

Collaboration graph
[legend]
List of all members.

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 ProcessorNEW ()

Static Public Attributes

static const string NAME = "normalize.maxmin"

Protected Member Functions

float calc_sigma (EMData *image) const
float calc_mean (EMData *image) const

Detailed Description

normalizes an image.

mean -> (maxval-minval)/2; std dev = (maxval+minval)/2;

Definition at line 4353 of file processor.h.


Member Function Documentation

float NormalizeMaxMinProcessor::calc_mean EMData image  )  const [protected, virtual]
 

Implements EMAN::NormalizeProcessor.

Definition at line 3724 of file processor.cpp.

References EMAN::EMData::get_attr(), and LOGWARN.

03725 {
03726         if (!image) {
03727                 LOGWARN("NULL Image");
03728                 return 0;
03729         }
03730         float maxval = image->get_attr("maximum");
03731         float minval = image->get_attr("minimum");
03732         return (maxval - minval) / 2;
03733 }

float NormalizeMaxMinProcessor::calc_sigma EMData image  )  const [protected, virtual]
 

Reimplemented from EMAN::NormalizeProcessor.

Definition at line 3713 of file processor.cpp.

References EMAN::EMData::get_attr(), and LOGWARN.

03714 {
03715         if (!image) {
03716                 LOGWARN("NULL Image");
03717                 return 0;
03718         }
03719         float maxval = image->get_attr("maximum");
03720         float minval = image->get_attr("minimum");
03721         return (maxval + minval) / 2;
03722 }

string EMAN::NormalizeMaxMinProcessor::get_desc  )  const [inline, virtual]
 

Get the descrition of this specific processor.

This function must be overwritten by a subclass.

Returns:
The description of this processor.

Implements EMAN::Processor.

Definition at line 4366 of file processor.h.

04367                 {
04368                         return "normalizes an image. mean -> (maxval-minval)/2; std dev = (maxval+minval)/2;";
04369                 }

string EMAN::NormalizeMaxMinProcessor::get_name  )  const [inline, virtual]
 

Get the processor's name.

Each processor is identified by a unique name.

Returns:
The processor's name.

Implements EMAN::Processor.

Definition at line 4356 of file processor.h.

References NAME.

04357                 {
04358                         return NAME;
04359                 }

static Processor* EMAN::NormalizeMaxMinProcessor::NEW  )  [inline, static]
 

Definition at line 4361 of file processor.h.

04362                 {
04363                         return new NormalizeMaxMinProcessor();
04364                 }


Member Data Documentation

const string NormalizeMaxMinProcessor::NAME = "normalize.maxmin" [static]
 

Definition at line 4371 of file processor.h.

Referenced by get_name().


The documentation for this class was generated from the following files:
Generated on Mon Jul 19 13:07:04 2010 for EMAN2 by  doxygen 1.4.4