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

EMAN::CutToZeroProcessor Class Reference

f(x) = x-minval if x >= minval; f(x) = 0 if x < minval More...

#include <processor.h>

Inheritance diagram for EMAN::CutToZeroProcessor:

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

Collaboration graph
[legend]
List of all members.

Public Member Functions

string get_name () const
 Get the processor's name.
TypeDict get_param_types () const
 Get processor parameter information in a dictionary.
string get_desc () const
 Get the descrition of this specific processor.

Static Public Member Functions

ProcessorNEW ()

Static Public Attributes

const string NAME = "threshold.belowtozero_cut"

Protected Member Functions

void process_pixel (float *x) const

Detailed Description

f(x) = x-minval if x >= minval; f(x) = 0 if x < minval

Parameters:
minval the value that will be set to zero - all values below will also be set to zero. Values above get minval subtracted from them

Definition at line 1786 of file processor.h.


Member Function Documentation

string EMAN::CutToZeroProcessor::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 1804 of file processor.h.

01805                 {
01806                         return "f(x) = x-minval if x >= minval; f(x) = 0 if x < minval.";
01807                 }

string EMAN::CutToZeroProcessor::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 1789 of file processor.h.

01790                 {
01791                         return NAME;
01792                 }

TypeDict EMAN::CutToZeroProcessor::get_param_types  )  const [inline, virtual]
 

Get processor parameter information in a dictionary.

Each parameter has one record in the dictionary. Each record contains its name, data-type, and description.

Returns:
A dictionary containing the parameter info.

Reimplemented from EMAN::Processor.

Definition at line 1797 of file processor.h.

References EMAN::TypeDict::put().

01798                 {
01799                         TypeDict d;
01800                         d.put("minval", EMObject::FLOAT, "the value that will be set to zero - all values below will also be set to zero. Values above get minval subtracted from them" );
01801                         return d;
01802                 }

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

Definition at line 1793 of file processor.h.

01794                 {
01795                         return new CutToZeroProcessor();
01796                 }

void EMAN::CutToZeroProcessor::process_pixel float *  x  )  const [inline, protected, virtual]
 

Implements EMAN::RealPixelProcessor.

Definition at line 1812 of file processor.h.

References x.

01813                 {
01814                         *x = *x - value;
01815                         if (*x < 0) {
01816                                 *x = 0;
01817                         }
01818                 }


Member Data Documentation

const string CutToZeroProcessor::NAME = "threshold.belowtozero_cut" [static]
 

Definition at line 99 of file processor.cpp.


The documentation for this class was generated from the following files:
Generated on Tue Jul 12 13:50:56 2011 for EMAN2 by  doxygen 1.3.9.1