NOMAD Source  Version 4.0.0 Beta
Eval.hpp File Reference

Evaluation at a point. More...

#include <functional>
#include "../Eval/BBOutput.hpp"
#include "../Param/EvalParameters.hpp"
#include "../nomad_nsbegin.hpp"
#include "../nomad_nsend.hpp"
Include dependency graph for Eval.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Eval
 Class for the representation of an evaluation at a point. More...
 

Typedefs

typedef std::unique_ptr< EvalEvalUPtr
 Definition for evaluation unique pointer. More...
 

Enumerations

enum  EvalStatusType {
  EvalStatusType::EVAL_NOT_STARTED,
  EvalStatusType::EVAL_FAILED,
  EvalStatusType::EVAL_ERROR,
  EvalStatusType::EVAL_USER_REJECTED,
  EvalStatusType::EVAL_CONS_H_OVER,
  EvalStatusType::EVAL_OK,
  EvalStatusType::EVAL_IN_PROGRESS,
  EvalStatusType::EVAL_WAIT,
  EvalStatusType::EVAL_STATUS_UNDEFINED
}
 Type for an evaluation status. More...
 

Functions

std::string enumStr (const EvalStatusType evalStatus)
 Utility to convert an eval status to a string. More...
 
std::ostream & operator<< (std::ostream &out, const EvalStatusType &evalStatus)
 Output raw eval status. More...
 
std::istream & operator>> (std::istream &is, EvalStatusType &evalStatus)
 Input eval status. More...
 

Detailed Description

Evaluation at a point.

Author
Viviane Rochon Montplaisir
Date
March 2017
See also
Eval.cpp

Definition in file Eval.hpp.

Typedef Documentation

◆ EvalUPtr

typedef std::unique_ptr<Eval> EvalUPtr

Definition for evaluation unique pointer.

Definition at line 384 of file Eval.hpp.

Enumeration Type Documentation

◆ EvalStatusType

enum EvalStatusType
strong

Type for an evaluation status.

Idea to implement: Eval diffentiates between a BB evaluation that failed (failure of the black box) and an evaluation that was interrupted (failure cause is external to the black box).
There is also states for evaluations that are not yet started, and evaluations that are currently running.

Todo:
These statuses should be made 100% clear. Add something in the name that says if we can re-evaluate the point or not. Even add some User Cases.
Enumerator
EVAL_NOT_STARTED 

Evaluation has not been done yet. Initial status.

EVAL_FAILED 

Evaluation failure. Do not re-submit.

EVAL_ERROR 

Evaluation did not proceed normally. May be submitted again.

EVAL_USER_REJECTED 

Evaluation was rejected by user. May be submitted again.

EVAL_CONS_H_OVER 

Evaluation was rejected because constraint violation was higher than hMax. May be submitted again.

EVAL_OK 

Correct evaluation.

EVAL_IN_PROGRESS 

Evaluation in progress.

EVAL_WAIT 

Evaluation in progress for another instance of the same point: Wait for evaluation to be done.

EVAL_STATUS_UNDEFINED 

Undefined evaluation status.

Definition at line 80 of file Eval.hpp.

81 {
82  EVAL_NOT_STARTED, ///< Evaluation has not been done yet. Initial status.
83  EVAL_FAILED, ///< Evaluation failure. Do not re-submit.
84  EVAL_ERROR, ///< Evaluation did not proceed normally. May be submitted again.
85  EVAL_USER_REJECTED, ///< Evaluation was rejected by user. May be submitted again
86  EVAL_CONS_H_OVER, ///< Evaluation was rejected because constraint violation was higher than hMax. May be submitted again.
87  EVAL_OK, ///< Correct evaluation
88  EVAL_IN_PROGRESS, ///< Evaluation in progress
89  EVAL_WAIT, ///< Evaluation in progress for another instance of the same point: Wait for evaluation to be done.
90  EVAL_STATUS_UNDEFINED ///< Undefined evaluation status
91 };

Function Documentation

◆ enumStr()

std::string enumStr ( const EvalStatusType  evalStatus)

Utility to convert an eval status to a string.

◆ operator<<()

std::ostream& operator<< ( std::ostream &  out,
const EvalStatusType evalStatus 
)

Output raw eval status.

Does not do the same as enumStr.

◆ operator>>()

std::istream& operator>> ( std::istream &  is,
EvalStatusType evalStatus 
)

Input eval status.

EvalStatusType::EVAL_IN_PROGRESS
@ EVAL_IN_PROGRESS
Evaluation in progress.
EvalStatusType::EVAL_CONS_H_OVER
@ EVAL_CONS_H_OVER
Evaluation was rejected because constraint violation was higher than hMax. May be submitted again.
EvalStatusType::EVAL_ERROR
@ EVAL_ERROR
Evaluation did not proceed normally. May be submitted again.
EvalStatusType::EVAL_FAILED
@ EVAL_FAILED
Evaluation failure. Do not re-submit.
EvalStatusType::EVAL_NOT_STARTED
@ EVAL_NOT_STARTED
Evaluation has not been done yet. Initial status.
EvalStatusType::EVAL_OK
@ EVAL_OK
Correct evaluation.
EvalStatusType::EVAL_STATUS_UNDEFINED
@ EVAL_STATUS_UNDEFINED
Undefined evaluation status.
EvalStatusType::EVAL_WAIT
@ EVAL_WAIT
Evaluation in progress for another instance of the same point: Wait for evaluation to be done.
EvalStatusType::EVAL_USER_REJECTED
@ EVAL_USER_REJECTED
Evaluation was rejected by user. May be submitted again.