Initialize, finalize, and query the Feel++ environment.
The Environment class is used to initialize, finalize, and query the Feel++ environment. It will typically be used in the main() function of a program, which will create a single instance of Environment initialized with the arguments passed to the program:
The instance of Environment will initialize Feel++ (by calling MPI, PETSc, SLEPc and MAdLib initialization routines) in its constructor and finalize in its destructor.
Inherits noncopyable.
Inherited by Feel::Environment.
Public Types | |
Typedefs | |
| typedef WorldComm | worldcomm_type |
|
typedef boost::shared_ptr < WorldComm > | worldcomm_ptrtype |
Public Member Functions | |
Constructors, destructor | |
| Environment () | |
| Environment (int &argc, char **&argv) | |
| template<class ArgumentPack > | |
| Environment (ArgumentPack const &args) | |
| void | init (int argc, char **argv, po::options_description const &desc, AboutData const &about) |
| ~Environment () | |
Static Public Member Functions | |
Accessors | |
| static bool | initialized () |
| static bool | finalized () |
| static WorldComm & | worldComm () |
| static std::vector< WorldComm > const & | worldsComm (int n) |
|
static std::vector< WorldComm > const & | worldsCommGroupBySubspace (int n) |
| static WorldComm const & | masterWorldComm (int n) |
| static int | numberOfProcessors () |
| static int | rank () |
| static po::variables_map const & | vm () |
| static AboutData const & | about () |
| static po::options_description const & | optionsDescription () |
Mutators | |
| static void | setWorldComm (WorldComm &worldcomm) |
Methods | |
| static std::string | rootRepository () |
| static std::string | findFile (std::string const &filename) |
| static std::vector< std::string > | geoPathList () |
| static std::string | localGeoRepository () |
| static boost::tuple < std::string, bool > | systemGeoRepository () |
| static std::string | localConfigRepository () |
| static boost::tuple < std::string, bool > | systemConfigRepository () |
| static MemoryUsage | logMemoryUsage (std::string const &message) |
| static void | setLogs (std::string const &prefix) |
get variables_map from options_description desc More... | |
| template<typename Observer > | |
| static void | addDeleteObserver (Observer const &obs) |
| template<typename Observer > | |
| static void | addDeleteObserver (boost::shared_ptr< Observer > const &obs) |
| static void | clearSomeMemory () |
| static const fs::path & | scratchDirectory () |
| Feel::detail::Environment::Environment | ( | ) |
| Feel::detail::Environment::Environment | ( | int & | argc, |
| char **& | argv | ||
| ) |
| Feel::detail::Environment::~Environment | ( | ) |
Shuts down the Feel environment.
If this Environment object was used to initialize the Feel environment, and the Feel environment has not already been shut down (finalized), this destructor will shut down the Feel environment.
|
static |
Determine if the MPI environment has already been finalized.
The routine is equivalent to a call to MPI_Finalized.
true if the MPI environment has been finalized.
|
static |
Find a file. The lookup is as follows:
localGeoRepository() which is usually $HOME/feel/geosystemGeoRepository() which is usually $FEELPP_DIR/share/feel/geo If filename is not found, then the empty string is returned. References localGeoRepository(), and systemGeoRepository().
|
static |
References localGeoRepository(), and systemGeoRepository().
|
static |
Determine if the MPI environment has already been initialized.
This routine is equivalent to a call to MPI_Initialized.
true if the MPI environment has been initialized.
|
static |
$HOME/feel/config) References rootRepository().
|
static |
$HOME/feel/geo) References rootRepository().
|
static |
print resident memory usage as well as PETSc malloc usage in log file
| message | message to print to identity the associated memory operation |
|
static |
return master world comm associated with a color map of size n
|
inlinestatic |
return number of processors
|
inlinestatic |
return options description data structure
|
inlinestatic |
return the rank in global mpi communicator
|
static |
$HOME/feel)
|
inlinestatic |
|
static |
get variables_map from options_description desc
set log files
| prefix | prefix for log filenames |
|
inlinestatic |
set the static worldcomm
|
static |
/usr/share/feel/config or /usr/local/share/feel/config) and true or false whether the directory exists or not References Feel::Info::prefix().
|
static |
/usr/share/feel/geo or /usr/local/share/feel/geo) and true or false whether the directory exists or not References Feel::Info::prefix().
|
inlinestatic |
return variables_map
|
inlinestatic |
return the worldcomm (static)
|
static |
return n sub world communicators
1.8.5