SENSEI
A frame work for generic in situ analytics
ConfigurableAnalysis.h
1 #ifndef sensei_ConfigurableAnalysis_h
2 #define sensei_ConfigurableAnalysis_h
3 
4 #include "AnalysisAdaptor.h"
5 
6 #include <string>
7 #include <mpi.h>
8 
9 /// @cond
10 namespace pugi { class xml_node; }
11 /// @endcond
12 
13 namespace sensei
14 {
15 /** An adaptor that creates and configures one or more adaptors from XML. When
16  * the Execute method is invoked the calls are forwarded to the active
17  * instances. The supported adaptors include:
18  *
19  * | Class | Description |
20  * | ----- | ----------- |
21  * | sensei::Histogram | Computes histograms |
22  * | sensei::ADIOS2AnalysisAdaptor | The write side of the ADIOS2 transport |
23  * | sensei::HDF5AnalysisAdaptor | The write side of the HDF5 transport |
24  * | sensei::AscentAnalysisAdaptor | Processes simulation data using Ascent |
25  * | sensei::CatalystAnalysisAdaptor | Processes simulation data using ParaView Catalyst |
26  * | sensei::LibsimAnalysisAdaptor | Processes simulation data using VisIt Libsim |
27  * | sensei::Autocorrelation | Compute autocorrelation of simulation data over time |
28  * | sensei::VTKPosthocIO | Writes simulation data to disk in a SVTK format |
29  * | sensei::VTKAmrWriter | Writes simulation data to disk in a SVTK format |
30  * | sensei::PythonAnalysis | Invokes user provided Pythons scripts that process simulation data |
31  * | sensei::SliceExtract | Computes planar slices and iso-surfaces on simulation data |
32  * | sensei::DataBinning | Bins point/particle data onto a cartesian grid with arbitrary axes |
33  * | sensei::ParticleDensity | Computes particle spatial density on a cartesian grid |
34  *
35  */
36 class SENSEI_EXPORT ConfigurableAnalysis : public AnalysisAdaptor
37 {
38 public:
39  /// creates a new instance.
40  static ConfigurableAnalysis *New();
41 
42  senseiTypeMacro(ConfigurableAnalysis, AnalysisAdaptor);
43 
44  void PrintSelf(ostream& os, svtkIndent indent) override;
45 
46  int SetCommunicator(MPI_Comm comm) override;
47 
48  void SetVerbose(int val) override;
49 
50  void SetAsynchronous(int val) override;
51 
52  void SetDeviceId(int val) override;
53  void SetDevicesToUse(int val) override;
54  void SetDeviceStart(int val) override;
55  void SetDeviceStride(int val) override;
56 
57  /// Initialize the adaptor using the configuration specified.
58  int Initialize(const std::string &filename);
59 
60  /// Initialize the adaptor using the configuration specified.
61  int Initialize(const pugi::xml_node &root);
62 
63  /// Invokes the Execute method on the currently configured adaptors.
64  bool Execute(DataAdaptor *data, DataAdaptor **result) override;
65 
66  /// Invokes the Finalize method on the currently configured adaptors.
67  int Finalize() override;
68 
69 protected:
72 
74  void operator=(const ConfigurableAnalysis&) = delete;
75 
76 private:
77  struct InternalsType;
78  InternalsType *Internals;
79 };
80 
81 }
82 
83 #endif
int Initialize(MPI_Comm comm, const std::string &fileName, InTransitDataAdaptor *&dataAdaptor)
Creates a sensei::ConfigurableAnalysis adaptor and sensei::InTransitDataAdaptor based on a SENSEI XML...
The base class for data consumers.
Definition: AnalysisAdaptor.h:24
An adaptor that creates and configures one or more adaptors from XML.
Definition: ConfigurableAnalysis.h:36
SENSEI.
Definition: ADIOS2AnalysisAdaptor.h:27
Definition: ADIOS2DataAdaptor.h:10
Base class that defines the interface for fetching data from a simulation.
Definition: DataAdaptor.h:25