https://mooseframework.inl.gov
SamplerParameterTransfer.h
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://mooseframework.inl.gov
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #pragma once
11 
12 // MOOSE includes
14 
15 // Forward declarations
16 class SamplerReceiver;
17 
22 {
23 public:
25 
30  virtual void execute() override;
31 
35  virtual void executeToMultiapp() override;
36 
37 protected:
46  std::map<SamplerReceiver *, std::map<std::string, std::vector<Real>>>
47  getReceivers(unsigned int app_index, const std::vector<std::string> & args);
48 
50  const std::vector<std::string> & _parameter_names;
51 
54 
55 private:
59  static std::vector<FEProblemBase *>
61  const std::vector<std::string> & multiapp_names);
62 };
const std::vector< std::string > & _parameter_names
Storage for the list of parameters to control.
std::map< SamplerReceiver *, std::map< std::string, std::vector< Real > > > getReceivers(unsigned int app_index, const std::vector< std::string > &args)
Based on command line args, return a map between SamplerReceiver objects and the parameter-value pair...
The class creates an additional API to allow Transfers to work when running the StochasticTools<FullS...
SamplerParameterTransfer(const InputParameters &parameters)
virtual void executeToMultiapp() override
Methods used when running in batch mode (see SamplerFullSolveMultiApp)
dof_id_type _global_index
Current global index for batch execution.
A Control object for receiving data from a master application Sampler object.
Copy each row from each DenseMatrix to the sub-applications SamplerReceiver object.
static std::vector< FEProblemBase * > getMultiAppProblemsHelper(FEProblemBase &base_problem, const std::vector< std::string > &multiapp_names)
Helper function that recursively finds feproblem pointers from nested multiapps.
const InputParameters & parameters() const
uint8_t dof_id_type
virtual void execute() override
Traditional Transfer callback.
static InputParameters validParams()