BootstrapConfig#
-
class BootstrapConfig : public helayers::SaveableBasic#
A configuration of the Bootstrap process via various parameter setups.
Public Functions
-
inline void validate() const#
Validates that the configuration is valid, and throws an error otherwise.
- Throws:
runtime_error –
-
void toJson(JsonWrapper &jw, const std::string &prefix) const#
Populates the content of this object into a JSON wrapper.
- Parameters:
jw – The JSON wrapper to populate.
prefix – An optional prefix. Attributes will be written as a sub-tree under this given prefix.
-
void fromJson(const JsonWrapper &jw, const std::string &prefix)#
Populates this object from a JSON wrapper.
- Parameters:
jw – The JSON wrapper to populate from.
prefix – An optional prefix. Attributes will be taken from a sub-tree under this given prefix.
-
virtual std::streamoff save(std::ostream &stream) const override#
Saves this object to a stream in binary form.
Returns the number of bytes written to the output stream.
- Parameters:
stream – [in] output stream to write to
-
virtual std::streamoff load(std::istream &stream) override#
Loads this object from the given stream.
Returns the number of bytes read from the input stream.
- Parameters:
stream – [in] input stream to read from
Public Members
-
bool supportComplexData = false#
If true then the slots to be bootstrapped may contain complex values and the bootstrap will take more time.
If you know that all the slots are real (with no imaginary component) then set this to false (the default).
-
bool duplicateRealInput = false#
If true then the bootstrap will assume that all the slots contain the same value, and will run faster.
The default is not to make this assumption.
-
int targetChainIndex = -1#
The bootstrap will at this level in the chain index.
-
int minChainIndexForBootstrapping = -1#
The bootstrap must be performed no lower than this level in the chain index.
-
Verbosity verbose = VERBOSITY_NONE#
Verbosity of debug printing.
-
bool storeEncMatrices = true#
Should the large FFT matrices be stored to file so that on the next run they will be loaded rather than re-computed? This slows down the first Bootstrap, but speeds up the subsequent runs.
-
bool loadEncMatrices = true#
Should the large FFT matrices be loaded from a file if it exists? Loading is faster than recomputing, but requires setting the storeEncMatrices flag in the previous run.
-
BootstrapRange range = BootstrapRange::DEFAULT_RANGE#
determines the range of supported values for bootstrapping
Friends
-
friend bool operator==(const BootstrapConfig &bc1, const BootstrapConfig &bc2)#
-
inline void validate() const#