prune-trace: add switch to disable sample weighting

In the sampling step, the --no-weighting switch disables the
equivalence-class weighting by using a weight of one instead of the
equivalence-class size.  This is usually not a good idea, and should
only be used for demonstration purposes, or if the fault model
requires weight-less sampling.

Change-Id: Id903d1924c6ecbcd217815aa5ce9271560130071
This commit is contained in:
Horst Schirmeier
2014-12-06 00:19:17 +01:00
parent a1e3b31cd5
commit b2b53380f4
2 changed files with 12 additions and 4 deletions

View File

@ -16,12 +16,13 @@
class FESamplingPruner : public Pruner {
fail::CommandLine::option_handle SAMPLESIZE;
fail::CommandLine::option_handle USE_KNOWN_RESULTS;
fail::CommandLine::option_handle NO_WEIGHTING;
unsigned m_samplesize;
bool m_use_known_results;
bool m_use_known_results, m_weighting;
public:
FESamplingPruner() : m_samplesize(0), m_use_known_results(false) { }
FESamplingPruner() : m_samplesize(0), m_use_known_results(false), m_weighting(true) { }
virtual std::string method_name() { return "FESampling"; }
virtual bool commandline_init();
virtual bool prune_all();