Version: SMASH-2.2
smash::OutputParameters Struct Reference

#include <outputparameters.h>

Helper structure for Experiment to hold output options and parameters.

Experiment has one member of this struct.

Definition at line 25 of file outputparameters.h.

Collaboration diagram for smash::OutputParameters:
[legend]

Public Member Functions

 OutputParameters ()
 Default constructor, useful for tests. More...
 
 OutputParameters (Configuration &&conf)
 Constructor from configuration. More...
 
bool get_coll_extended (std::string name) const
 Pass correct extended flag to binary collision output constructor. More...
 

Public Attributes

ThreeVector td_position
 Point, where thermodynamic quantities are calculated. More...
 
DensityType td_dens_type
 Type (e.g., baryon/pion/hadron) of thermodynamic quantity. More...
 
bool td_rho_eckart
 Print out Eckart rest frame density of type td_dens_type or not? More...
 
bool td_tmn
 Print out energy-momentum tensor of type td_dens_type or not? More...
 
bool td_tmn_landau
 Print out energy-momentum tensor in Landau rest frame (of type td_dens_type) or not? More...
 
bool td_v_landau
 Print out Landau velocity of type td_dens_type or not? More...
 
bool td_jQBS
 Print out QBS 4-currents or not? More...
 
bool td_smearing
 Whether smearing is on or off; WARNING : if smearing is off, then final result is in GeV instead of GeV/fm3. More...
 
bool td_only_participants
 Flag reporting whether only participants are considered (true) or also spectators (false) More...
 
bool part_extended
 Extended format for particles output. More...
 
OutputOnlyFinal part_only_final
 Print only final particles in event. More...
 
bool coll_extended
 Extended format for collisions output. More...
 
bool coll_printstartend
 Print initial and final particles in event into collision output. More...
 
bool dil_extended
 Extended format for dilepton output. More...
 
bool photons_extended
 Extended format for photon output. More...
 
bool ic_extended
 Extended initial conditions output. More...
 
Configuration subcon_for_rivet
 Rivet specfic setup configurations. More...
 

Constructor & Destructor Documentation

◆ OutputParameters() [1/2]

smash::OutputParameters::OutputParameters ( )
inline

Default constructor, useful for tests.

Definition at line 27 of file outputparameters.h.

28  : td_position(ThreeVector()),
30  td_rho_eckart(false),
31  td_tmn(false),
32  td_tmn_landau(false),
33  td_v_landau(false),
34  td_jQBS(false),
35  td_smearing(true),
36  td_only_participants(false),
37  part_extended(false),
39  coll_extended(false),
40  coll_printstartend(false),
41  dil_extended(false),
42  photons_extended(false),
43  ic_extended(false),
44  subcon_for_rivet(0) {}
@ Yes
Print only final-state particles.
bool dil_extended
Extended format for dilepton output.
bool coll_extended
Extended format for collisions output.
bool part_extended
Extended format for particles output.
bool photons_extended
Extended format for photon output.
bool td_v_landau
Print out Landau velocity of type td_dens_type or not?
bool td_tmn_landau
Print out energy-momentum tensor in Landau rest frame (of type td_dens_type) or not?
bool td_jQBS
Print out QBS 4-currents or not?
OutputOnlyFinal part_only_final
Print only final particles in event.
DensityType td_dens_type
Type (e.g., baryon/pion/hadron) of thermodynamic quantity.
bool td_tmn
Print out energy-momentum tensor of type td_dens_type or not?
bool td_smearing
Whether smearing is on or off; WARNING : if smearing is off, then final result is in GeV instead of G...
bool td_rho_eckart
Print out Eckart rest frame density of type td_dens_type or not?
bool td_only_participants
Flag reporting whether only participants are considered (true) or also spectators (false)
bool ic_extended
Extended initial conditions output.
ThreeVector td_position
Point, where thermodynamic quantities are calculated.
Configuration subcon_for_rivet
Rivet specfic setup configurations.
bool coll_printstartend
Print initial and final particles in event into collision output.

◆ OutputParameters() [2/2]

smash::OutputParameters::OutputParameters ( Configuration &&  conf)
inlineexplicit

Constructor from configuration.

Definition at line 47 of file outputparameters.h.

47  : OutputParameters() {
49 
50  if (conf.has_value({"Thermodynamics"})) {
51  auto subcon = conf["Thermodynamics"];
52  if (subcon.has_value({"Position"})) {
53  const std::array<double, 3> a = subcon.take({"Position"});
54  td_position = ThreeVector(a[0], a[1], a[2]);
55  }
56  std::set<ThermodynamicQuantity> quan = subcon.take({"Quantities"});
58  td_tmn = (quan.count(ThermodynamicQuantity::Tmn) > 0);
61  td_jQBS = (quan.count(ThermodynamicQuantity::j_QBS) > 0);
62  td_dens_type = subcon.take({"Type"}, DensityType::Baryon);
65  logg[LExperiment].warn(
66  "Requested Thermodynamics output with Density type None. ",
67  "Change the density type to avoid output being dropped.");
68  }
69  td_smearing = subcon.take({"Smearing"}, true);
70  td_only_participants = subcon.take({"Only_Participants"}, false);
71  }
72 
73  if (conf.has_value({"Particles"})) {
74  part_extended = conf.take({"Particles", "Extended"}, false);
76  conf.take({"Particles", "Only_Final"}, OutputOnlyFinal::Yes);
77  }
78 
79  if (conf.has_value({"Collisions"})) {
80  coll_extended = conf.take({"Collisions", "Extended"}, false);
81  coll_printstartend = conf.take({"Collisions", "Print_Start_End"}, false);
82  }
83 
84  if (conf.has_value({"Dileptons"})) {
85  dil_extended = conf.take({"Dileptons", "Extended"}, false);
86  }
87 
88  if (conf.has_value({"Photons"})) {
89  photons_extended = conf.take({"Photons", "Extended"}, false);
90  }
91 
92  if (conf.has_value({"Initial_Conditions"})) {
93  ic_extended = conf.take({"Initial_Conditions", "Extended"}, false);
94  }
95 
96  if (conf.has_value({"Rivet"})) {
97  subcon_for_rivet = conf["Rivet"];
98  }
99  }
#define SMASH_SOURCE_LOCATION
Hackery that is required to output the location in the source code where the log statement occurs.
Definition: logging.h:243
std::array< einhard::Logger<>, std::tuple_size< LogArea::AreaTuple >::value > logg
An array that stores all pre-configured Logger objects.
Definition: logging.cc:39
static constexpr int LExperiment
OutputParameters()
Default constructor, useful for tests.

Member Function Documentation

◆ get_coll_extended()

bool smash::OutputParameters::get_coll_extended ( std::string  name) const
inline

Pass correct extended flag to binary collision output constructor.

Parameters
[in]name(File)name of the output.
Returns
Extended flag for binary output.

Definition at line 106 of file outputparameters.h.

106  {
107  if (name == "Collisions") {
108  return coll_extended;
109  } else if (name == "Dileptons") {
110  return dil_extended;
111  } else if (name == "Photons") {
112  return photons_extended;
113  } else {
114  return false; // error
115  }
116  }

Member Data Documentation

◆ td_position

ThreeVector smash::OutputParameters::td_position

Point, where thermodynamic quantities are calculated.

Definition at line 119 of file outputparameters.h.

◆ td_dens_type

DensityType smash::OutputParameters::td_dens_type

Type (e.g., baryon/pion/hadron) of thermodynamic quantity.

Definition at line 122 of file outputparameters.h.

◆ td_rho_eckart

bool smash::OutputParameters::td_rho_eckart

Print out Eckart rest frame density of type td_dens_type or not?

Definition at line 125 of file outputparameters.h.

◆ td_tmn

bool smash::OutputParameters::td_tmn

Print out energy-momentum tensor of type td_dens_type or not?

Definition at line 128 of file outputparameters.h.

◆ td_tmn_landau

bool smash::OutputParameters::td_tmn_landau

Print out energy-momentum tensor in Landau rest frame (of type td_dens_type) or not?

Definition at line 134 of file outputparameters.h.

◆ td_v_landau

bool smash::OutputParameters::td_v_landau

Print out Landau velocity of type td_dens_type or not?

Definition at line 137 of file outputparameters.h.

◆ td_jQBS

bool smash::OutputParameters::td_jQBS

Print out QBS 4-currents or not?

Definition at line 140 of file outputparameters.h.

◆ td_smearing

bool smash::OutputParameters::td_smearing

Whether smearing is on or off; WARNING : if smearing is off, then final result is in GeV instead of GeV/fm3.

Definition at line 146 of file outputparameters.h.

◆ td_only_participants

bool smash::OutputParameters::td_only_participants

Flag reporting whether only participants are considered (true) or also spectators (false)

Definition at line 152 of file outputparameters.h.

◆ part_extended

bool smash::OutputParameters::part_extended

Extended format for particles output.

Definition at line 155 of file outputparameters.h.

◆ part_only_final

OutputOnlyFinal smash::OutputParameters::part_only_final

Print only final particles in event.

Definition at line 158 of file outputparameters.h.

◆ coll_extended

bool smash::OutputParameters::coll_extended

Extended format for collisions output.

Definition at line 161 of file outputparameters.h.

◆ coll_printstartend

bool smash::OutputParameters::coll_printstartend

Print initial and final particles in event into collision output.

Definition at line 164 of file outputparameters.h.

◆ dil_extended

bool smash::OutputParameters::dil_extended

Extended format for dilepton output.

Definition at line 167 of file outputparameters.h.

◆ photons_extended

bool smash::OutputParameters::photons_extended

Extended format for photon output.

Definition at line 170 of file outputparameters.h.

◆ ic_extended

bool smash::OutputParameters::ic_extended

Extended initial conditions output.

Definition at line 173 of file outputparameters.h.

◆ subcon_for_rivet

Configuration smash::OutputParameters::subcon_for_rivet

Rivet specfic setup configurations.

Definition at line 176 of file outputparameters.h.


The documentation for this struct was generated from the following file: