SyTen
envvars.cpp File Reference

Implementation for inc/util/info_reordering.h. More...

#include <cstdlib>
#include <cstring>
#include <string>
#include "inc/util/envvars.h"
#include "inc/util/macros.h"
#include "inc/util/log.h"
#include "inc/util/memory_sampler.h"
#include "inc/util/cached_type.h"
#include "inc/util/cached_type_async.h"
#include "inc/util/cuda_support.h"
+ Include dependency graph for envvars.cpp:

Namespaces

namespace  syten
 Syten namespace.
 
namespace  syten::EnvVars
 Namespace for generic static variables initialised from environment variables.
 

Functions

void syten::EnvVars::init_env_bool (char const *name, bool &target, std::string const &msg="")
 Sets target to true if name is a set environment variables, if msg is non-zero, then also prints msg. More...
 
template<typename Function >
void syten::EnvVars::init_env_fun (char const *name, Function f)
 Calls the specified function f is an environment variable name exists. More...
 
template<typename Target , typename Function >
void syten::EnvVars::init_env_var (char const *name, Target &target, Function f, std::string const &msg="")
 Sets target to f(str) with str initialised from the environment variable name, if set. More...
 
template<typename Target >
void syten::EnvVars::init_env_var (char const *name, Target &target, std::string const &msg="")
 Sets target to str, with str initialised from the environment variable name, if set. More...
 
void syten::EnvVars::init_env_vars ()
 Initialises generic environment variables, called from SYTEN_BPO_INIT. More...
 

Variables

std::size_t syten::EnvVars::cuda_num_handles = 10
 Number of handles to initialise for each GPU, set via SYTEN_CUDA_NUM_HANDLES. More...
 
std::size_t syten::EnvVars::cuda_size_to_gpu = 1024 * 1024
 When deciding in an algorithm whether to move a tensor to the GPU or from the GPU, use this value (in bytes) as the threshold. More...
 
bool syten::EnvVars::dbg_ad = false
 Set via SYTEN_DBG_AD. More...
 
TruncationType syten::EnvVars::default_tpo_truncate = TruncationType::Delinearise
 Set via SYTEN_DEFAULT_TPO_TRUNCATE, one of the non-default truncation types. More...
 
bool syten::EnvVars::dense_tts = false
 Set via SYTEN_DENSE_TTS, enabled temporary transpose storage. More...
 
bool syten::EnvVars::disable_backtraces = false
 Set via SYTEN_DISABLE_BACKTRACES, does what it says. More...
 
bool syten::EnvVars::disable_history = false
 Set via SYTEN_NO_HISTORY, disables adding new elements to History() objects. More...
 
bool syten::EnvVars::disable_mpi = false
 Set via SYTEN_DISABLE_MPI, does what it says. More...
 
bool syten::EnvVars::dynarray_allocs = false
 Set via SYTEN_INFO_DYNARRAY_ALLOC, causes DynArray-allocators to print the size of the allocated memory region. More...
 
bool syten::EnvVars::info_reordering = false
 Set via SYTEN_INFO_REORDERING, causes info about relevant reordering in dense products to be printed. More...
 
int syten::EnvVars::minimise_ranks = 0
 Set via SYTEN_MINIMISE_RANKS, enables less memory-intensive algorithms by reducing tensor ranks at the cost of computational efficiency. More...
 
bool syten::EnvVars::mpo_parse_notrunc = false
 Set via SYTEN_MPO_PARSE_NOTRUNC, disables truncation of MPO during parsing. More...
 
bool syten::EnvVars::no_lz4_compression = false
 If this flag is set, no compression is done during saving. More...
 
bool syten::EnvVars::prod_check_early = false
 Set via SYTEN_PROD_CHECK_EARLY and from the Pyten toolkit. More...
 
HandleFermions syten::EnvVars::stensor_handle_ferm = HandleFermions::y()
 Disables all fermionic signs in STensors. More...
 
bool syten::EnvVars::stensor_register = false
 Set to true to register every syten::STensor object into the STensor registry. More...
 
int syten::EnvVars::t3n_dmrg_energy_precision = 15
 precision of energy output in T3N-DMRG. More...
 
bool syten::EnvVars::tensor_time = false
 Set via SYTEN_TENSOR_TIME, enables timing of tensor products and decompositions. More...
 
bool syten::EnvVars::use_external_debugger = false
 Set via SYTEN_USE_EXTERN_DEBUG, disables termination handling and backtrace printing. More...
 
bool syten::EnvVars::varapplyortho_timing = false
 Set via SYTEN_VARAPPLYORTHO_TIMING, enables detailed print-outs of timing information in apply_op_orthogonalise_fit(). More...
 

Detailed Description

Implementation for inc/util/info_reordering.h.