Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Related Pages

SctAnalysis::TrimRangeAlgorithm Class Reference

Algorithm considers many trim range scans, possibly over many different ranges, makes fits to graphs, and works out the best trim range to use. More...

#include <TrimRangeAlgorithm.h>

Inheritance diagram for SctAnalysis::TrimRangeAlgorithm:

Inheritance graph
[legend]
Collaboration diagram for SctAnalysis::TrimRangeAlgorithm:

Collaboration graph
[legend]

Public Member Functions

virtual bool canAnalyze () const
 Should check to see if the analysis can be performed.

virtual void analyze ()
 Does the analysis.

virtual void loadData ()
 Called to indicate the algorithm should try and load as much data as it can - perhaps by calling loadAllFits or loadAllRaws().

virtual shared_ptr< SctData::TestResultcreateTestResult () const
 Called if the TestResult needs to be created.

virtual ~TrimRangeAlgorithm () throw ()
 destructor

 TrimRangeAlgorithm (const TestData &testData, const string &moduleName, const AnalysisAlgorithm &alg) throw ()
 constructor

virtual boost::shared_ptr<
AnalysisAlgorithm
clone (const TestData &testData, const string &moduleName) const throw ()
 over-ride

vector< TrimRangecreateRanges (const SctData::TestResult &r) throw ()
 find which trim ranges and points are represented in the data

bool allowTrimRangeVariation () const throw ()
 allow trim range variation between chips?

bool allowTrimTargetVariation () const throw ()
 allow trim target variation between chips?


Static Public Member Functions

void doTrimDataFit (SctData::TrimRangeTestResult::ChipTrimData &chipData) throw ()
 Fit the graph of data points with a linear fit.

unsigned nTargets () throw ()
 Number of trim targets to consider.

float firstTarget () throw ()
 First trim target to consider.

float targetStep () throw ()
 Step between trim targets to consider.


Static Private Member Functions

shared_ptr< const SctData::TrimRangeTestResult::ChipTrimgetChipTrim (const SctData::TrimRangeTestResult::ChipTrimData &data, const float target, short unsigned irange) throw ()

Static Private Attributes

bool inMap
 static var to force addition to map

bool s_targetVariation
bool s_rangeVariation

Detailed Description

Algorithm considers many trim range scans, possibly over many different ranges, makes fits to graphs, and works out the best trim range to use.


Input: TrimRangeTest Output: TrimRangeTestResult

Definition at line 16 of file TrimRangeAlgorithm.h.


Constructor & Destructor Documentation

virtual SctAnalysis::TrimRangeAlgorithm::~TrimRangeAlgorithm  )  throw () [inline, virtual]
 

destructor

Definition at line 27 of file TrimRangeAlgorithm.h.

SctAnalysis::TrimRangeAlgorithm::TrimRangeAlgorithm const TestData testData,
const string &  moduleName,
const AnalysisAlgorithm alg
throw () [inline]
 

constructor

Definition at line 31 of file TrimRangeAlgorithm.h.


Member Function Documentation

bool SctAnalysis::TrimRangeAlgorithm::allowTrimRangeVariation  )  const throw () [inline]
 

allow trim range variation between chips?

Definition at line 52 of file TrimRangeAlgorithm.h.

Referenced by analyze().

bool SctAnalysis::TrimRangeAlgorithm::allowTrimTargetVariation  )  const throw () [inline]
 

allow trim target variation between chips?

Definition at line 54 of file TrimRangeAlgorithm.h.

Referenced by analyze().

void SctAnalysis::TrimRangeAlgorithm::analyze  )  [virtual]
 

Does the analysis.

Should only be called after canAnalyze() returns true. Should not be called is isDone() returns true. It should also do any final initialization of the TestResult which requires data to be present

Exceptions:
any Exception

Implements SctAnalysis::AnalysisAlgorithm.

Definition at line 48 of file TrimRangeAlgorithm.cpp.

References allowTrimRangeVariation(), allowTrimTargetVariation(), createRanges(), SctData::DefectList::defectSeverityEncompassingElement(), doTrimDataFit(), firstTarget(), SctData::Stats< T >::getAt(), SctData::ModuleConfiguration::getChipConfiguration(), SctAnalysis::AnalysisAlgorithm::getFit(), SctAnalysis::AnalysisAlgorithm::getTestResult(), SctData::ChipConfiguration::isMasked(), SctData::Stats< T >::mean(), nTargets(), SctAnalysis::TrimRangeAlgorithm::TrimRange::points, SctData::SERIOUS, targetStep(), SctData::UNUSEABLE, SctData::Stat< T >::valid, SctData::Stat< T >::value, and SctData::Stats< T >::var().

Here is the call graph for this function:

bool SctAnalysis::TrimRangeAlgorithm::canAnalyze  )  const [virtual]
 

Should check to see if the analysis can be performed.

Probably wants to call hasAllRaws() or hasAllFits().

Exceptions:
no exceotions.

Implements SctAnalysis::AnalysisAlgorithm.

Definition at line 40 of file TrimRangeAlgorithm.cpp.

References SctAnalysis::AnalysisAlgorithm::hasAllFits().

Here is the call graph for this function:

shared_ptr< AnalysisAlgorithm > SctAnalysis::TrimRangeAlgorithm::clone const TestData testData,
const string &  moduleName
const throw () [virtual]
 

over-ride

Implements SctAnalysis::AnalysisAlgorithm.

Definition at line 29 of file TrimRangeAlgorithm.cpp.

std::vector< TrimRangeAlgorithm::TrimRange > SctAnalysis::TrimRangeAlgorithm::createRanges const SctData::TestResult r  )  throw ()
 

find which trim ranges and points are represented in the data

Definition at line 433 of file TrimRangeAlgorithm.cpp.

Referenced by analyze().

shared_ptr< TestResult > SctAnalysis::TrimRangeAlgorithm::createTestResult  )  const [virtual]
 

Called if the TestResult needs to be created.

Exceptions:
nothing. 

Implements SctAnalysis::AnalysisAlgorithm.

Definition at line 44 of file TrimRangeAlgorithm.cpp.

void SctAnalysis::TrimRangeAlgorithm::doTrimDataFit SctData::TrimRangeTestResult::ChipTrimData chipData  )  throw () [static]
 

Fit the graph of data points with a linear fit.

linear least-squares fit

Definition at line 398 of file TrimRangeAlgorithm.cpp.

References SctData::Stat< T >::valid, and SctData::Stat< T >::value.

Referenced by analyze().

float SctAnalysis::TrimRangeAlgorithm::firstTarget  )  throw () [inline, static]
 

First trim target to consider.

Definition at line 44 of file TrimRangeAlgorithm.h.

Referenced by analyze().

void SctAnalysis::TrimRangeAlgorithm::loadData  )  [virtual]
 

Called to indicate the algorithm should try and load as much data as it can - perhaps by calling loadAllFits or loadAllRaws().

This is guarenteed to be called shortly before analyze().

Implements SctAnalysis::AnalysisAlgorithm.

Definition at line 36 of file TrimRangeAlgorithm.cpp.

References SctAnalysis::AnalysisAlgorithm::loadAllFits().

Here is the call graph for this function:

unsigned SctAnalysis::TrimRangeAlgorithm::nTargets  )  throw () [inline, static]
 

Number of trim targets to consider.

Definition at line 42 of file TrimRangeAlgorithm.h.

Referenced by analyze().

float SctAnalysis::TrimRangeAlgorithm::targetStep  )  throw () [inline, static]
 

Step between trim targets to consider.

Definition at line 46 of file TrimRangeAlgorithm.h.

Referenced by analyze().


Field Documentation

bool SctAnalysis::TrimRangeAlgorithm::inMap [static, private]
 

static var to force addition to map

Definition at line 27 of file TrimRangeAlgorithm.cpp.


The documentation for this class was generated from the following files:
Generated on Thu Jul 15 09:51:58 2004 for SCT DAQ/DCS Software - C++ by doxygen 1.3.5