https://mooseframework.inl.gov
AdaptiveSamplingCompletedPostprocessor.C
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 
11 
12 #include "Sampler.h"
13 
15 
18 {
20  params.addRequiredParam<SamplerName>(
21  "sampler", "Sampler for which we want to know if the sampling has been completed.");
22  params.addClassDescription(
23  "Informs whether a sampler has finished its sampling (1 = completed, 0 otherwise).");
24  return params;
25 }
26 
28  const InputParameters & parameters)
29  : GeneralPostprocessor(parameters), _sampler(getSampler("sampler")), _sampling_completed(0)
30 {
31 }
32 
33 void
35 {
37 }
38 
39 void
41 {
43 }
44 
45 Real
47 {
48  return _sampling_completed;
49 }
void gatherMax(T &value)
const Sampler & _sampler
Sampler for which we want to know if the sampling has been completed.
void addRequiredParam(const std::string &name, const std::string &doc_string)
static InputParameters validParams()
virtual bool isAdaptiveSamplingCompleted() const
bool _sampling_completed
Whether the sampling has been completed.
registerMooseObject("StochasticToolsApp", AdaptiveSamplingCompletedPostprocessor)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void addClassDescription(const std::string &doc_string)
AdaptiveSamplingCompletedPostprocessor(const InputParameters &parameters)