#include <controlPoints.h>
Public Member Functions | |
simplexScheme () | |
void | adapt (std::map< std::string, std::pair< int, int > > &controlPointSpace, std::map< std::string, int > &newControlPoints, const int phase_id, instrumentedData &allData) |
Inform the control point framework that a named control point affects the priorities of some array. | |
Private Types | |
enum | simplexStateEnumT { beginning, reflecting, expanding, contracting, doneExpanding, stillContracting } |
The states used by the Nelder Mead Simplex Algorithm. More... | |
typedef enum simplexScheme::simplexStateEnumT | simplexStateT |
Private Member Functions | |
void | computeCentroidBestWorst (std::map< std::string, std::pair< int, int > > &controlPointSpace, std::map< std::string, int > &newControlPoints, const int phase_id, instrumentedData &allData) |
void | doReflection (std::map< std::string, std::pair< int, int > > &controlPointSpace, std::map< std::string, int > &newControlPoints, const int phase_id, instrumentedData &allData) |
Replace the worst point with its reflection across the centroid. | |
void | doExpansion (std::map< std::string, std::pair< int, int > > &controlPointSpace, std::map< std::string, int > &newControlPoints, const int phase_id, instrumentedData &allData) |
Replace the newly tested reflection with a further expanded version of itself. | |
void | doContraction (std::map< std::string, std::pair< int, int > > &controlPointSpace, std::map< std::string, int > &newControlPoints, const int phase_id, instrumentedData &allData) |
Replace the newly tested reflection with a further expanded version of itself. | |
std::vector< double > | pointCoords (instrumentedData &allData, int i) |
int | keepInRange (int v, int lb, int ub) |
void | printSimplex (instrumentedData &allData) |
Private Attributes | |
std::set< int > | simplexIndices |
The indices into the allData->phases that correspond to the current simplex used one of the tuning schemes. | |
simplexStateT | simplexState |
double | alpha |
Reflection coefficient. | |
double | beta |
double | gamma |
int | firstSimplexPhase |
The first phase that was used by the this scheme. This helps us ignore a few startup phases that are out of our control. | |
int | worstPhase |
double | worstTime |
std::vector< double > | worst |
std::vector< double > | centroid |
int | bestPhase |
double | bestTime |
std::vector< double > | best |
std::vector< double > | P |
int | pPhase |
std::vector< double > | P2 |
int | p2Phase |
std::set< int > | stillMustContractList |
bool | useBestKnown |
Definition at line 599 of file controlPoints.h.
typedef enum simplexScheme::simplexStateEnumT simplexScheme::simplexStateT [private] |
enum simplexScheme::simplexStateEnumT [private] |
The states used by the Nelder Mead Simplex Algorithm.
The transitions between these states are displayed in the NelderMeadStateDiagram.pdf diagram.
Definition at line 604 of file controlPoints.h.
simplexScheme::simplexScheme | ( | ) | [inline] |
Definition at line 656 of file controlPoints.h.
Referenced by adapt(), doContraction(), doExpansion(), and doReflection().
void simplexScheme::printSimplex | ( | instrumentedData & | allData | ) | [inline, private] |
Definition at line 664 of file controlPoints.h.
References instrumentedData::phases, PUP::s, and simplexIndices.
Referenced by doContraction(), doExpansion(), and doReflection().
std::set<int> simplexScheme::simplexIndices [private] |
The indices into the allData->phases that correspond to the current simplex used one of the tuning schemes.
Definition at line 607 of file controlPoints.h.
Referenced by adapt(), computeCentroidBestWorst(), and printSimplex().
simplexStateT simplexScheme::simplexState [private] |
Definition at line 608 of file controlPoints.h.
Referenced by adapt(), doContraction(), doExpansion(), and doReflection().
double simplexScheme::alpha [private] |
Reflection coefficient.
Definition at line 611 of file controlPoints.h.
Referenced by doReflection(), and simplexScheme().
double simplexScheme::beta [private] |
double simplexScheme::gamma [private] |
int simplexScheme::firstSimplexPhase [private] |
The first phase that was used by the this scheme. This helps us ignore a few startup phases that are out of our control.
Definition at line 619 of file controlPoints.h.
Referenced by adapt().
int simplexScheme::worstPhase [private] |
Definition at line 622 of file controlPoints.h.
Referenced by adapt(), computeCentroidBestWorst(), doContraction(), doExpansion(), and doReflection().
double simplexScheme::worstTime [private] |
Definition at line 623 of file controlPoints.h.
Referenced by adapt(), and computeCentroidBestWorst().
std::vector<double> simplexScheme::worst [private] |
Definition at line 624 of file controlPoints.h.
Referenced by adapt(), computeCentroidBestWorst(), doContraction(), and doReflection().
std::vector<double> simplexScheme::centroid [private] |
Definition at line 627 of file controlPoints.h.
Referenced by computeCentroidBestWorst(), doContraction(), doExpansion(), and doReflection().
int simplexScheme::bestPhase [private] |
double simplexScheme::bestTime [private] |
Definition at line 631 of file controlPoints.h.
Referenced by adapt(), and computeCentroidBestWorst().
std::vector<double> simplexScheme::best [private] |
Definition at line 632 of file controlPoints.h.
Referenced by adapt(), computeCentroidBestWorst(), and doReflection().
std::vector<double> simplexScheme::P [private] |
Definition at line 635 of file controlPoints.h.
Referenced by adapt(), doContraction(), doExpansion(), and doReflection().
int simplexScheme::pPhase [private] |
std::vector<double> simplexScheme::P2 [private] |
int simplexScheme::p2Phase [private] |
Definition at line 640 of file controlPoints.h.
Referenced by adapt(), doContraction(), and doExpansion().
std::set<int> simplexScheme::stillMustContractList [private] |
bool simplexScheme::useBestKnown [private] |