|
Doxygen
1.9.1
|
Helper class that stores data from dynamic construction of a Global grid. More...
#include <tsgDConstructGridGlobal.hpp>
Public Types | |
| enum class | AddPointResult { tensor_incomplete , tensor_complete , tensor_missing } |
| Defines the result of adding a point to the list of know points with values. More... | |
Public Member Functions | |
| DynamicConstructorDataGlobal (size_t cnum_dimensions, size_t cnum_outputs) | |
| Constructor, requires that the dimension and the number of model outputs is specified. | |
| template<typename iomode > | |
| DynamicConstructorDataGlobal (std::istream &is, size_t cnum_dimensions, size_t cnum_outputs, iomode) | |
| Read constructor. | |
| ~DynamicConstructorDataGlobal ()=default | |
| Default destructor, release all used memory and erase all stored data. | |
| template<bool use_ascii> | |
| void | write (std::ostream &os) const |
| Write the data to a stream using ascii or binary format. | |
| void | restrictData (int ibegin, int iend) |
| Restrict data between ibegin and iend entries. | |
| int | getMaxTensor () const |
| Returns the maximum index of any of the stored tensors. | |
| double | getMaxTensorWeight () const |
| Returns the maximum tensor weight. | |
| void | reloadPoints (std::function< int(int)> getNumPoints) |
| Called after read, reinitializes the points and loaded structures for the tensors. | |
| void | clearTesnors () |
| Delete the tensors with non-negative weights, i.e., clear all but the tensors selected by the initial grid. | |
| MultiIndexSet | getInitialTensors () const |
| Get a set of all tensors with negative weight, i.e., the tensors selected for the initial run. | |
| void | addTensor (const int *tensor, std::function< int(int)> getNumPoints, double weight) |
| Add a new tensor to the candidates, with the given weight and using getNumPoints() to define the associated nodes. | |
| MultiIndexSet | getNodesIndexes () |
| Get the node indexes of the points associated with the candidate tensors, the order is the same as the tensors sorted by ascending weight. | |
| AddPointResult | addNewNode (const std::vector< int > &point, const std::vector< double > &value) |
| Add a new data point with the index and the value, returns information about the tensor. | |
| void | ejectCompleteTensor (MultiIndexSet const ¤t_tensors, MultiIndexSet &new_tensors, MultiIndexSet &new_points, StorageSet &vals) |
| Returns a new set of tensors, points and values that can be added to the current tensors. | |
Helper class that stores data from dynamic construction of a Global grid.
The class stores candidate tensors with corresponding weights as well as the model data provided by the user. When enough data has been computed to complete a tensor, the tensor can be ejected with the points and model data returned in a format that is easy to incorporate within the data structures of the GridGlobal class.
Defines the result of adding a point to the list of know points with values.