WarpX
FlushFormatSensei.H
Go to the documentation of this file.
1 #ifndef WARPX_FLUSHFORMATSENSEI_H_
2 #define WARPX_FLUSHFORMATSENSEI_H_
3 
4 #include "FlushFormat.H"
5 
6 #include <AMReX_AmrMesh.H>
7 #if defined(AMREX_USE_SENSEI_INSITU)
9 #else
10 namespace amrex {
11 using AmrMeshParticleInSituBridge = void;
12 }
13 #endif
14 
33 {
34 public:
37 
38  FlushFormatSensei(const FlushFormatSensei &) = delete;
39  void operator=(const FlushFormatSensei &) = delete;
40 
46  FlushFormatSensei (amrex::AmrMesh *amr_mesh, std::string diag_name);
47 
49  virtual void WriteToFile (
50  const amrex::Vector<std::string> varnames,
53  const amrex::Vector<int> iteration, const double time,
54  const amrex::Vector<ParticleDiag>& particle_diags, int nlev,
55  const std::string prefix, int file_min_digits,
56  bool plot_raw_fields,
57  bool plot_raw_fields_guards,
58  const bool use_pinned_pc = false,
59  bool isBTD = false, int snapshotID = -1,
60  int bufferID = 1, int numBuffers = 1,
61  const amrex::Geometry& full_BTD_snapshot = amrex::Geometry(),
62  bool isLastBTDFlush = false,
63  const amrex::Vector<int>& totalParticlesFlushedAlready = amrex::Vector<int>() ) const override;
64 
68  void WriteParticles(const amrex::Vector<ParticleDiag>& particle_diags) const;
69 
70 private:
71  std::string m_insitu_config;
72  int m_insitu_pin_mesh = 0;
73  amrex::AmrMeshParticleInSituBridge * m_insitu_bridge = nullptr;
74  amrex::AmrMesh * m_amr_mesh = nullptr;
75 };
76 
77 #endif // WARPX_FLUSHFORMATSENSEI_H_
Definition: FlushFormat.H:10
std::string m_insitu_config
Definition: FlushFormatSensei.H:71
This class aims at dumping performing in-situ diagnostics with SENSEI. In particular, function WriteToFile takes fields and particles as input arguments, and calls amrex functions to do the in-situ visualization.
Definition: FlushFormatSensei.H:32