AutoPas  3.0.0
Loading...
Searching...
No Matches
AutoPasDecl.h
Go to the documentation of this file.
1
6#pragma once
7
8#include <memory>
9#include <set>
10
33
34namespace autopas {
35
36// Forward declare Handler so that including this header does not include the whole library with all
37// containers and traversals.
38template <class Particle_T>
39class LogicHandler;
40
46template <class Particle_T>
47class AutoPas {
48 public:
52 using ParticleType = Particle_T;
53
59
65
71
77
82 explicit AutoPas(std::ostream &logOutputStream = std::cout);
83
89 explicit AutoPas(const std::string &logFileName);
90
91 ~AutoPas();
92
98 AutoPas &operator=(AutoPas &&other) noexcept;
99
108 void init();
109
116 std::vector<Particle_T> resizeBox(const std::array<double, 3> &boxMin, const std::array<double, 3> &boxMax);
117
121 void forceRetune();
122
128 void finalize() {
129 if (not _externalMPICommunicator) {
130 AutoPas_MPI_Comm_free(&_tuningStrategyFactoryInfo.autopasMpiCommunicator);
131 }
132 }
133
140 [[nodiscard]] std::vector<Particle_T> updateContainer();
141
151 void reserve(size_t numParticles);
152
162 void reserve(size_t numParticles, size_t numHaloParticles);
163
172 void addParticle(const Particle_T &p);
173
181 template <class Collection>
182 void addParticles(Collection &&particles);
183
193 template <class Collection, class F>
194 void addParticlesIf(Collection &&particles, F predicate);
195
203 void addHaloParticle(const Particle_T &haloParticle);
204
212 template <class Collection>
213 void addHaloParticles(Collection &&particles);
214
224 template <class Collection, class F>
225 void addHaloParticlesIf(Collection &&particles, F predicate);
226
231 void deleteAllParticles();
232
241 void deleteParticle(IteratorT &iter);
242
249
262 bool deleteParticle(Particle_T &particle);
263
270 template <class Functor>
272
280 IteratorT begin(IteratorBehavior behavior = IteratorBehavior::ownedOrHalo);
281
286 ConstIteratorT begin(IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const;
287
295 template <typename Lambda>
296 void forEachParallel(Lambda forEachLambda, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
297 // TODO lgaertner: parallelize with kokkos integration
298 withStaticContainerType(getContainer(), [&](auto &container) { container.forEach(forEachLambda, behavior); });
299 }
300
305 template <typename Lambda>
306 void forEachParallel(Lambda forEachLambda, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
307 // TODO lgaertner: parallelize with kokkos integration
308 withStaticContainerType(getContainer(), [&](auto &container) { container.forEach(forEachLambda, behavior); });
309 }
310
317 template <typename Lambda>
318 void forEach(Lambda forEachLambda, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
319 withStaticContainerType(getContainer(), [&](auto &container) { container.forEach(forEachLambda, behavior); });
320 }
321
326 template <typename Lambda>
327 void forEach(Lambda forEachLambda, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
328 withStaticContainerType(getContainer(), [&](auto &container) { container.forEach(forEachLambda, behavior); });
329 }
330
340 template <typename Lambda, typename A>
341 void reduceParallel(Lambda reduceLambda, A &result, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
342 // TODO lgaertner: parallelize with kokkos integration
343 withStaticContainerType(getContainer(), [&](auto &container) { container.reduce(reduceLambda, result, behavior); });
344 }
345
350 template <typename Lambda, typename A>
351 void reduceParallel(Lambda reduceLambda, A &result, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
352 // TODO lgaertner: parallelize with kokkos integration
353 withStaticContainerType(getContainer(), [&](auto &container) { container.reduce(reduceLambda, result, behavior); });
354 }
355
364 template <typename Lambda, typename A>
365 void reduce(Lambda reduceLambda, A &result, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
366 withStaticContainerType(getContainer(), [&](auto &container) { container.reduce(reduceLambda, result, behavior); });
367 }
368
373 template <typename Lambda, typename A>
374 void reduce(Lambda reduceLambda, A &result, IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
375 withStaticContainerType(getContainer(), [&](auto &container) { container.reduce(reduceLambda, result, behavior); });
376 }
377
382 ConstIteratorT cbegin(IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const { return begin(behavior); }
383
394 [[nodiscard]] constexpr bool end() const { return false; }
395
407 RegionIteratorT getRegionIterator(const std::array<double, 3> &lowerCorner, const std::array<double, 3> &higherCorner,
408 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo);
413 RegionConstIteratorT getRegionIterator(const std::array<double, 3> &lowerCorner,
414 const std::array<double, 3> &higherCorner,
415 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const;
416
426 template <typename Lambda>
427 void forEachInRegionParallel(Lambda forEachLambda, const std::array<double, 3> &lowerCorner,
428 const std::array<double, 3> &higherCorner,
429 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
430 // TODO (lgaertner): parallelize with kokkos integration
431 withStaticContainerType(getContainer(), [&](auto &container) {
432 container.forEachInRegion(forEachLambda, lowerCorner, higherCorner, behavior);
433 });
434 }
435
440 template <typename Lambda>
441 void forEachInRegionParallel(Lambda forEachLambda, const std::array<double, 3> &lowerCorner,
442 const std::array<double, 3> &higherCorner,
443 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
444 // TODO (lgaertner): parallelize with kokkos integration
445 withStaticContainerType(getContainer(), [&](auto &container) {
446 container.forEachInRegion(forEachLambda, lowerCorner, higherCorner, behavior);
447 });
448 }
449
458 template <typename Lambda>
459 void forEachInRegion(Lambda forEachLambda, const std::array<double, 3> &lowerCorner,
460 const std::array<double, 3> &higherCorner,
461 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
462 withStaticContainerType(getContainer(), [&](auto &container) {
463 container.forEachInRegion(forEachLambda, lowerCorner, higherCorner, behavior);
464 });
465 }
466
471 template <typename Lambda>
472 void forEachInRegion(Lambda forEachLambda, const std::array<double, 3> &lowerCorner,
473 const std::array<double, 3> &higherCorner,
474 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
475 withStaticContainerType(getContainer(), [&](auto &container) {
476 container.forEachInRegion(forEachLambda, lowerCorner, higherCorner, behavior);
477 });
478 }
479
491 template <typename Lambda, typename A>
492 void reduceInRegionParallel(Lambda reduceLambda, A &result, const std::array<double, 3> &lowerCorner,
493 const std::array<double, 3> &higherCorner,
494 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
495 // TODO lgaertner: parallelize with kokkos integration
496 withStaticContainerType(getContainer(), [&](auto &container) {
497 container.reduceInRegion(reduceLambda, result, lowerCorner, higherCorner, behavior);
498 });
499 }
500
505 template <typename Lambda, typename A>
506 void reduceInRegionParallel(Lambda reduceLambda, A &result, const std::array<double, 3> &lowerCorner,
507 const std::array<double, 3> &higherCorner,
508 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
509 // TODO lgaertner: parallelize with kokkos integration
510 withStaticContainerType(getContainer(), [&](auto &container) {
511 container.reduceInRegion(reduceLambda, result, lowerCorner, higherCorner, behavior);
512 });
513 }
514
525 template <typename Lambda, typename A>
526 void reduceInRegion(Lambda reduceLambda, A &result, const std::array<double, 3> &lowerCorner,
527 const std::array<double, 3> &higherCorner,
528 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) {
529 withStaticContainerType(getContainer(), [&](auto &container) {
530 container.reduceInRegion(reduceLambda, result, lowerCorner, higherCorner, behavior);
531 });
532 }
533
538 template <typename Lambda, typename A>
539 void reduceInRegion(Lambda reduceLambda, A &result, const std::array<double, 3> &lowerCorner,
540 const std::array<double, 3> &higherCorner,
541 IteratorBehavior behavior = IteratorBehavior::ownedOrHalo) const {
542 withStaticContainerType(getContainer(), [&](auto &container) {
543 container.reduceInRegion(reduceLambda, result, lowerCorner, higherCorner, behavior);
544 });
545 }
546
552 double getVerletSkin() { return _logicHandlerInfo.verletSkin; };
553
559 [[nodiscard]] size_t getNumberOfParticles(IteratorBehavior behavior = IteratorBehavior::owned) const;
560
565 [[nodiscard]] unsigned long getContainerType() const;
566
571 [[nodiscard]] const std::array<double, 3> &getBoxMin() const;
572
577 [[nodiscard]] const std::array<double, 3> &getBoxMax() const;
578
583 [[nodiscard]] bool searchSpaceIsTrivial() const;
584
589 void setBoxMin(const std::array<double, 3> &boxMin) { _logicHandlerInfo.boxMin = boxMin; }
590
595 void setBoxMax(const std::array<double, 3> &boxMax) { _logicHandlerInfo.boxMax = boxMax; }
596
601 [[nodiscard]] double getCutoff() const { return _logicHandlerInfo.cutoff; }
602
607 void setCutoff(double cutoff) {
608 if (cutoff <= 0.0) {
609 utils::ExceptionHandler::exception("Error: Cutoff has to be positive {} <= 0.0!", cutoff);
610 }
611 _logicHandlerInfo.cutoff = cutoff;
612 }
613
618 [[nodiscard]] const NumberSet<double> &getAllowedCellSizeFactors() const { return *_allowedCellSizeFactors; }
619
624 void setAllowedCellSizeFactors(const NumberSet<double> &allowedCellSizeFactors) {
625 if (allowedCellSizeFactors.getMin() <= 0.0) {
626 utils::ExceptionHandler::exception("Error: minimum cell size factor has to be positive {} <= 0.0!",
627 allowedCellSizeFactors.getMin());
628 }
629 _allowedCellSizeFactors = std::move(allowedCellSizeFactors.clone());
630 }
631
636 void setCellSizeFactor(double cellSizeFactor) {
637 if (cellSizeFactor <= 0.0) {
638 utils::ExceptionHandler::exception("Error: cell size factor has to be positive! {}<= 0.0!", cellSizeFactor);
639 }
640 _allowedCellSizeFactors = std::make_unique<NumberSetFinite<double>>(std::set<double>{cellSizeFactor});
641 }
642
647 void setVerletSkin(double verletSkin) { _logicHandlerInfo.verletSkin = verletSkin; }
648
654 void setDeltaT(double deltaT) { _logicHandlerInfo.deltaT = deltaT; }
655
660 [[nodiscard]] unsigned int getVerletRebuildFrequency() const { return _verletRebuildFrequency; }
661
666 void setVerletRebuildFrequency(unsigned int verletRebuildFrequency) {
667 _verletRebuildFrequency = verletRebuildFrequency;
668 }
673 [[nodiscard]] unsigned int getVerletClusterSize() const { return _logicHandlerInfo.verletClusterSize; }
674
679 void setVerletClusterSize(unsigned int verletClusterSize) { _logicHandlerInfo.verletClusterSize = verletClusterSize; }
680
685 [[nodiscard]] unsigned int getTuningInterval() const { return _autoTunerInfo.tuningInterval; }
686
691 void setTuningInterval(unsigned int tuningInterval) { _autoTunerInfo.tuningInterval = tuningInterval; }
692
697 [[nodiscard]] unsigned int getNumSamples() const { return _autoTunerInfo.maxSamples; }
698
703 void setNumSamples(unsigned int numSamples) { _autoTunerInfo.maxSamples = numSamples; }
704
710 void setEarlyStoppingFactor(double earlyStoppingFactor) { _autoTunerInfo.earlyStoppingFactor = earlyStoppingFactor; }
711
716 [[nodiscard]] bool getUseLOESSSmoothening() const { return _autoTunerInfo.useLOESSSmoothening; }
717
722 void setUseLOESSSmoothening(bool useLOESSSmoothening) { _autoTunerInfo.useLOESSSmoothening = useLOESSSmoothening; }
723
728 [[nodiscard]] unsigned int getMaxEvidence() const { return _tuningStrategyFactoryInfo.maxEvidence; }
729
734 void setMaxEvidence(unsigned int maxEvidence) { _tuningStrategyFactoryInfo.maxEvidence = maxEvidence; }
735
740 [[nodiscard]] double getRelativeOptimumRange() const { return _tuningStrategyFactoryInfo.relativeOptimumRange; }
741
746 void setRelativeOptimumRange(double relativeOptimumRange) {
747 _tuningStrategyFactoryInfo.relativeOptimumRange = relativeOptimumRange;
748 }
749
754 [[nodiscard]] unsigned int getMaxTuningPhasesWithoutTest() const {
755 return _tuningStrategyFactoryInfo.maxTuningPhasesWithoutTest;
756 }
757
762 void setMaxTuningPhasesWithoutTest(unsigned int maxTuningPhasesWithoutTest) {
763 _tuningStrategyFactoryInfo.maxTuningPhasesWithoutTest = maxTuningPhasesWithoutTest;
764 }
765
771 [[nodiscard]] double getRelativeBlacklistRange() const { return _tuningStrategyFactoryInfo.relativeBlacklistRange; }
772
777 void setRelativeBlacklistRange(double relativeBlacklistRange) {
778 _tuningStrategyFactoryInfo.relativeBlacklistRange = relativeBlacklistRange;
779 }
780
786 [[nodiscard]] unsigned int getEvidenceFirstPrediction() const {
787 return _tuningStrategyFactoryInfo.minNumberOfEvidence;
788 }
789
795 void setEvidenceFirstPrediction(unsigned int evidenceFirstPrediction) {
796 _tuningStrategyFactoryInfo.minNumberOfEvidence = evidenceFirstPrediction;
797 }
798
803 ExtrapolationMethodOption getExtrapolationMethodOption() const {
804 return _tuningStrategyFactoryInfo.extrapolationMethodOption;
805 }
806
811 void setExtrapolationMethodOption(ExtrapolationMethodOption extrapolationMethodOption) {
812 _tuningStrategyFactoryInfo.extrapolationMethodOption = extrapolationMethodOption;
813 }
814
819 [[nodiscard]] SelectorStrategyOption getSelectorStrategy() const { return _autoTunerInfo.selectorStrategy; }
820
826 void setSelectorStrategy(SelectorStrategyOption selectorStrategy) {
827 _autoTunerInfo.selectorStrategy = selectorStrategy;
828 }
829
834 const std::set<LoadEstimatorOption> &getAllowedLoadEstimators() const { return _allowedLoadEstimators; }
835
841 void setAllowedLoadEstimators(const std::set<LoadEstimatorOption> &allowedLoadEstimators) {
842 _allowedLoadEstimators = allowedLoadEstimators;
843 }
844
849 [[nodiscard]] const std::set<ContainerOption> &getAllowedContainers() const { return _allowedContainers; }
850
856 void setAllowedContainers(const std::set<ContainerOption> &allowedContainers) {
857 _allowedContainers = allowedContainers;
858 }
859
866 [[nodiscard]] const std::set<TraversalOption> &getAllowedTraversals(
867 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) const {
868 return _allowedTraversals.at(interactionType);
869 }
870
878 void setAllowedTraversals(const std::set<TraversalOption> &allowedTraversals,
879 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) {
880 if (interactionType == InteractionTypeOption::all) {
881 for (auto iType : InteractionTypeOption::getMostOptions()) {
882 _allowedTraversals[iType] = allowedTraversals;
883 }
884 } else {
885 _allowedTraversals[interactionType] = allowedTraversals;
886 }
887 }
888
895 [[nodiscard]] const std::set<DataLayoutOption> &getAllowedDataLayouts(
896 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) const {
897 return _allowedDataLayouts.at(interactionType);
898 }
899
907 void setAllowedDataLayouts(const std::set<DataLayoutOption> &allowedDataLayouts,
908 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) {
909 if (interactionType == InteractionTypeOption::all) {
910 for (auto iType : InteractionTypeOption::getMostOptions()) {
911 _allowedDataLayouts[iType] = allowedDataLayouts;
912 }
913 } else {
914 _allowedDataLayouts[interactionType] = allowedDataLayouts;
915 }
916 }
917
924 [[nodiscard]] const std::set<Newton3Option> &getAllowedNewton3Options(
925 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) const {
926 return _allowedNewton3Options.at(interactionType);
927 }
928
936 void setAllowedNewton3Options(const std::set<Newton3Option> &allowedNewton3Options,
937 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) {
938 if (interactionType == InteractionTypeOption::all) {
939 for (auto iType : InteractionTypeOption::getMostOptions()) {
940 _allowedNewton3Options[iType] = allowedNewton3Options;
941 }
942 } else {
943 _allowedNewton3Options[interactionType] = allowedNewton3Options;
944 }
945 }
946
956 [[nodiscard]] const std::set<VectorizationPatternOption> &getAllowedVecPatternOptions(
957 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) const {
958 return _allowedVecPatternsOptions.at(interactionType);
959 }
960
973 void setAllowedVecPatterns(const std::set<VectorizationPatternOption> &allowedVecPatterns,
974 const InteractionTypeOption interactionType = InteractionTypeOption::pairwise) {
975 auto applicableVecPatterns = allowedVecPatterns;
976 if (applicableVecPatterns.erase(VectorizationPatternOption::NA) > 0) {
977 AutoPasLog(WARN,
978 "The not-applicable (N/A) vectorization pattern is always included implicitly and does not need to "
979 "be set. It is removed from the allowed vectorization patterns.");
980 }
981 if (interactionType == InteractionTypeOption::all) {
982 for (auto iType : InteractionTypeOption::getMostOptions()) {
983 _allowedVecPatternsOptions[iType] = applicableVecPatterns;
984 }
985 } else {
986 _allowedVecPatternsOptions[interactionType] = applicableVecPatterns;
987 }
988 }
989
996 void setAllowedInteractionTypeOptions(const std::set<InteractionTypeOption> &allowedInteractionTypeOptions) {
997 _allowedInteractionTypeOptions = allowedInteractionTypeOptions;
998 }
999
1004 [[nodiscard]] std::unordered_map<InteractionTypeOption::Value, std::reference_wrapper<const Configuration>>
1006 std::unordered_map<InteractionTypeOption::Value, std::reference_wrapper<const Configuration>> currentConfigs;
1007 currentConfigs.reserve(_tuningManager->getAutoTuners().size());
1008
1009 for (const auto &[type, tuner] : _tuningManager->getAutoTuners()) {
1010 currentConfigs.emplace(type, std::cref(tuner->getCurrentConfig()));
1011 }
1012 return currentConfigs;
1013 }
1014
1019 [[nodiscard]] const std::vector<TuningStrategyOption> &getTuningStrategyOptions() const {
1020 return _tuningStrategyOptions;
1021 }
1022
1028 void setTuningStrategyOption(const std::vector<TuningStrategyOption> &tuningStrategyOptions) {
1029 _tuningStrategyOptions = tuningStrategyOptions;
1030 }
1031
1036 [[nodiscard]] const TuningMetricOption &getTuningMetricOption() const { return _autoTunerInfo.tuningMetric; }
1037
1044 _autoTunerInfo.tuningMetric = tuningMetricOption;
1045 }
1046
1051 [[nodiscard]] const EnergySensorOption &getEnergySensorOption() const { return _autoTunerInfo.energySensor; }
1052
1058 _autoTunerInfo.energySensor = energySensorOption;
1059 }
1060
1065 void setMPITuningMaxDifferenceForBucket(double MPITuningMaxDifferenceForBucket) {
1066 _tuningStrategyFactoryInfo.mpiTuningMaxDifferenceForBucket = MPITuningMaxDifferenceForBucket;
1067 }
1068
1073 void setMPITuningWeightForMaxDensity(double MPITuningWeightForMaxDensity) {
1074 _tuningStrategyFactoryInfo.mpiTuningWeightForMaxDensity = MPITuningWeightForMaxDensity;
1075 }
1076
1077// Only define the interface for the MPI communicator if AUTOPAS_INCLUDE_MPI=ON
1078// The internal implementation will use _autopasMPICommunicator with WrapMPI regardless of AUTOPAS_INCLUDE_MPI
1079#if defined(AUTOPAS_INCLUDE_MPI)
1085 void setMPICommunicator(MPI_Comm comm) { _tuningStrategyFactoryInfo.autopasMpiCommunicator = comm; }
1086
1091 MPI_Comm getMPICommunicator() { return _tuningStrategyFactoryInfo.autopasMpiCommunicator; }
1092#endif
1093
1099 void setOutputSuffix(const std::string &suffix) { _outputSuffix = suffix; }
1100
1107 double getMeanRebuildFrequency() { return _logicHandler->getMeanRebuildFrequency(); }
1108
1113 void setUseTuningLogger(bool useTuningLogger) { _useTuningStrategyLoggerProxy = useTuningLogger; }
1114
1119 void setRuleFileName(const std::string &ruleFileName) { _tuningStrategyFactoryInfo.ruleFileName = ruleFileName; }
1120
1125 void setFuzzyRuleFileName(const std::string &fuzzyRuleFileName) {
1126 _tuningStrategyFactoryInfo.fuzzyRuleFileName = fuzzyRuleFileName;
1127 }
1128
1133 const std::string &getRuleFileName() const { return _tuningStrategyFactoryInfo.ruleFileName; }
1134
1141 void setAoSSortingThreshold(size_t aosSortingThreshold) { _autoTunerInfo.aosSortingThreshold = aosSortingThreshold; }
1142
1147 size_t getAoSSortingThreshold() const { return _autoTunerInfo.aosSortingThreshold; }
1148
1154 void setSoASortingThreshold(size_t soaSortingThreshold) { _autoTunerInfo.soaSortingThreshold = soaSortingThreshold; }
1155
1160 size_t getSoASortingThreshold() const { return _autoTunerInfo.soaSortingThreshold; }
1161
1169 void setUseSortingThresholdBenchmark(bool useSortingThresholdBenchmark) {
1170 _logicHandlerInfo.useSortingThresholdBenchmark = useSortingThresholdBenchmark;
1171 }
1172
1173 private:
1175
1176 const autopas::ParticleContainerInterface<Particle_T> &getContainer() const;
1180 TuningStrategyFactoryInfo _tuningStrategyFactoryInfo{};
1184 AutoTunerInfo _autoTunerInfo{};
1188 LogicHandlerInfo _logicHandlerInfo{};
1192 bool _useTuningStrategyLoggerProxy{false};
1197 unsigned int _verletRebuildFrequency{100};
1202 std::vector<TuningStrategyOption> _tuningStrategyOptions{};
1207 std::set<ContainerOption> _allowedContainers{ContainerOption::getMostOptions()};
1212 std::unordered_map<InteractionTypeOption::Value, std::set<TraversalOption>> _allowedTraversals{
1213 {InteractionTypeOption::pairwise, TraversalOption::getMostPairwiseOptions()},
1214 {InteractionTypeOption::triwise, TraversalOption::getMostTriwiseOptions()}};
1219 std::unordered_map<InteractionTypeOption::Value, std::set<DataLayoutOption>> _allowedDataLayouts{
1220 {InteractionTypeOption::pairwise, DataLayoutOption::getMostOptions()},
1221 {InteractionTypeOption::triwise, DataLayoutOption::getMostOptions()}};
1225 std::unordered_map<InteractionTypeOption::Value, std::set<Newton3Option>> _allowedNewton3Options{
1226 {InteractionTypeOption::pairwise, Newton3Option::getMostOptions()},
1227 {InteractionTypeOption::triwise, Newton3Option::getMostOptions()}};
1231 std::unordered_map<InteractionTypeOption::Value, std::set<VectorizationPatternOption>> _allowedVecPatternsOptions{
1232 {InteractionTypeOption::pairwise, VectorizationPatternOption::getAllApplicablePatterns()},
1233 // Note: Currently Vectorization Patterns are not implemented for threebody interactions. p1xVec is used as
1234 // default.
1235 {InteractionTypeOption::triwise, std::set<VectorizationPatternOption>{VectorizationPatternOption::p1xVec}}};
1240 std::set<InteractionTypeOption> _allowedInteractionTypeOptions{InteractionTypeOption::pairwise};
1244 std::unique_ptr<NumberSet<double>> _allowedCellSizeFactors{
1245 std::make_unique<NumberSetFinite<double>>(std::set<double>({1.}))};
1250 std::set<LoadEstimatorOption> _allowedLoadEstimators{LoadEstimatorOption::getAllOptions()};
1254 std::unique_ptr<LogicHandler<Particle_T>> _logicHandler;
1255
1259 std::shared_ptr<TuningManager> _tuningManager;
1263 bool _externalMPICommunicator{false};
1268 std::string _outputSuffix{""};
1279 template <class F>
1280 void addParticlesAux(size_t numParticlesToAdd, size_t numHalosToAdd, size_t collectionSize, F loopBody);
1281}; // class AutoPas
1282} // namespace autopas
#define AutoPasLog(lvl, fmt,...)
Macro for logging providing common meta information without filename.
Definition: Logger.h:74
The AutoPas class is intended to be the main point of Interaction for the user.
Definition: AutoPasDecl.h:47
void setMaxEvidence(unsigned int maxEvidence)
Set maximum number of evidence for tuning.
Definition: AutoPasDecl.h:734
void setNumSamples(unsigned int numSamples)
Set number of samples taken per configuration during the tuning.
Definition: AutoPasDecl.h:703
void setAllowedNewton3Options(const std::set< Newton3Option > &allowedNewton3Options, const InteractionTypeOption interactionType=InteractionTypeOption::pairwise)
Set the list of allowed newton 3 options.
Definition: AutoPasDecl.h:936
void setSelectorStrategy(SelectorStrategyOption selectorStrategy)
Set the strategy of how to select a performance value for a piece of evidence from multiple time meas...
Definition: AutoPasDecl.h:826
void setFuzzyRuleFileName(const std::string &fuzzyRuleFileName)
Set fuzzy rule file name for the RuleBasedTuning.
Definition: AutoPasDecl.h:1125
size_t getSoASortingThreshold() const
Get the SoA sorting-threshold.
Definition: AutoPasDecl.h:1160
unsigned int getTuningInterval() const
Get tuning interval.
Definition: AutoPasDecl.h:685
unsigned int getMaxTuningPhasesWithoutTest() const
Get the maximum number of tuning phases before a configuration is certainly tested again.
Definition: AutoPasDecl.h:754
const std::set< TraversalOption > & getAllowedTraversals(const InteractionTypeOption interactionType=InteractionTypeOption::pairwise) const
Get the list of allowed traversals.
Definition: AutoPasDecl.h:866
std::vector< Particle_T > updateContainer()
Updates the container.
Definition: AutoPasImpl.h:213
void setTuningMetricOption(TuningMetricOption tuningMetricOption)
Setter for the tuning metric option.
Definition: AutoPasDecl.h:1043
void reduceInRegion(Lambda reduceLambda, A &result, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Execute code on all particles in a certain region as defined by a lambda function.
Definition: AutoPasDecl.h:539
autopas::ContainerIterator< Particle_T, false, true > RegionConstIteratorT
Define the const region iterator type for ease of use.
Definition: AutoPasDecl.h:76
const std::array< double, 3 > & getBoxMin() const
Get the lower corner of the container without the halo.
Definition: AutoPasImpl.h:326
unsigned int getNumSamples() const
Get number of samples taken per configuration during the tuning.
Definition: AutoPasDecl.h:697
unsigned int getMaxEvidence() const
Get maximum number of evidence for tuning.
Definition: AutoPasDecl.h:728
void setBoxMax(const std::array< double, 3 > &boxMax)
Set coordinates of the upper corner of the domain.
Definition: AutoPasDecl.h:595
void reduce(Lambda reduceLambda, A &result, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Reduce properties of particles as defined by a lambda function.
Definition: AutoPasDecl.h:374
void setUseTuningLogger(bool useTuningLogger)
Set if the tuning information should be logged to a file.
Definition: AutoPasDecl.h:1113
unsigned int getVerletRebuildFrequency() const
Get Verlet rebuild frequency.
Definition: AutoPasDecl.h:660
ConstIteratorT cbegin(IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Iterate over all particles by using for(auto iter = autoPas.begin(); iter.isValid(); ++iter)
Definition: AutoPasDecl.h:382
void addHaloParticles(Collection &&particles)
Adds all halo particles from the collection to the container.
Definition: AutoPasImpl.h:243
const std::set< VectorizationPatternOption > & getAllowedVecPatternOptions(const InteractionTypeOption interactionType=InteractionTypeOption::pairwise) const
Get the list of allowed vectorization pattern options.
Definition: AutoPasDecl.h:956
void reserve(size_t numParticles)
Reserve memory for a given number of particles in the container and logic layers.
Definition: AutoPasImpl.h:158
const std::string & getRuleFileName() const
Get the name / path of the rule file for the RuleBasedTuning.
Definition: AutoPasDecl.h:1133
void setRuleFileName(const std::string &ruleFileName)
Set rule file name for the RuleBasedTuning.
Definition: AutoPasDecl.h:1119
ExtrapolationMethodOption getExtrapolationMethodOption() const
Get extrapolation method for the prediction of the configuration performance.
Definition: AutoPasDecl.h:803
const std::set< DataLayoutOption > & getAllowedDataLayouts(const InteractionTypeOption interactionType=InteractionTypeOption::pairwise) const
Get the list of allowed data layouts.
Definition: AutoPasDecl.h:895
SelectorStrategyOption getSelectorStrategy() const
Get the selector configuration strategy.
Definition: AutoPasDecl.h:819
unsigned int getVerletClusterSize() const
Get Verlet cluster size.
Definition: AutoPasDecl.h:673
void addHaloParticlesIf(Collection &&particles, F predicate)
Adds all halo particles for which predicate(particle) == true to the container.
Definition: AutoPasImpl.h:249
void addParticles(Collection &&particles)
Adds all particles from the collection to the container.
Definition: AutoPasImpl.h:186
void setVerletSkin(double verletSkin)
Set length added to the cutoff for the Verlet lists' skin per timestep.
Definition: AutoPasDecl.h:647
void setOutputSuffix(const std::string &suffix)
Suffix for all output files produced by this instance of AutoPas, e.g.
Definition: AutoPasDecl.h:1099
void setMaxTuningPhasesWithoutTest(unsigned int maxTuningPhasesWithoutTest)
Set the maximum number of tuning phases before a configuration is certainly tested again.
Definition: AutoPasDecl.h:762
void setEnergySensorOption(EnergySensorOption energySensorOption)
Setter for the energy sensor.
Definition: AutoPasDecl.h:1057
unsigned long getContainerType() const
Returns the type of the currently used container.
Definition: AutoPasImpl.h:321
void forEach(Lambda forEachLambda, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Execute code on all particles as defined by a lambda function.
Definition: AutoPasDecl.h:318
const std::set< ContainerOption > & getAllowedContainers() const
Get the list of allowed containers.
Definition: AutoPasDecl.h:849
void deleteParticle(IteratorT &iter)
Deletes the particle behind the current iterator position and leaves the container in a valid state.
Definition: AutoPasImpl.h:275
void setEarlyStoppingFactor(double earlyStoppingFactor)
Set the earlyStoppingFactor for the auto tuner.
Definition: AutoPasDecl.h:710
void setMPITuningWeightForMaxDensity(double MPITuningWeightForMaxDensity)
Setter for the maxDensity-Weight in calculation for bucket distribution.
Definition: AutoPasDecl.h:1073
void reduceParallel(Lambda reduceLambda, A &result, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Reduce properties of particles as defined by a lambda function.
Definition: AutoPasDecl.h:351
void reduceInRegion(Lambda reduceLambda, A &result, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Execute code on all particles in a certain region as defined by a lambda function.
Definition: AutoPasDecl.h:526
void setEvidenceFirstPrediction(unsigned int evidenceFirstPrediction)
Set the number of tests that need to have happened for a configuration until the first predictions ar...
Definition: AutoPasDecl.h:795
void forEachParallel(Lambda forEachLambda, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
execute code on all particles in parallel as defined by a lambda function
Definition: AutoPasDecl.h:296
const EnergySensorOption & getEnergySensorOption() const
Getter for the energy sensor.
Definition: AutoPasDecl.h:1051
double getRelativeOptimumRange() const
Get the range for the optimum in which has to be to be tested.
Definition: AutoPasDecl.h:740
void finalize()
Free the AutoPas MPI communicator.
Definition: AutoPasDecl.h:128
void setCellSizeFactor(double cellSizeFactor)
Set allowed cell size factors to one element (only relevant for LinkedCells, VerletLists and VerletLi...
Definition: AutoPasDecl.h:636
void setRelativeBlacklistRange(double relativeBlacklistRange)
Set the range of the configurations that are not going to be blacklisted.
Definition: AutoPasDecl.h:777
unsigned int getEvidenceFirstPrediction() const
Get the number of tests that need to have happened for a configuration until the first predictions ar...
Definition: AutoPasDecl.h:786
void addParticlesIf(Collection &&particles, F predicate)
Adds all particles for which predicate(particle) == true to the container.
Definition: AutoPasImpl.h:192
double getRelativeBlacklistRange() const
For Predictive tuning: Get the relative cutoff for configurations to be blacklisted.
Definition: AutoPasDecl.h:771
void setTuningStrategyOption(const std::vector< TuningStrategyOption > &tuningStrategyOptions)
Setter for the tuning strategy option.
Definition: AutoPasDecl.h:1028
autopas::ContainerIterator< Particle_T, true, true > RegionIteratorT
Define the region iterator type for ease of use.
Definition: AutoPasDecl.h:70
void forEachParallel(Lambda forEachLambda, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
execute code on all particles in parallel as defined by a lambda function
Definition: AutoPasDecl.h:306
void setAllowedVecPatterns(const std::set< VectorizationPatternOption > &allowedVecPatterns, const InteractionTypeOption interactionType=InteractionTypeOption::pairwise)
Set the list of allowed vectorization pattern options For possible options, see options::Vectorizatio...
Definition: AutoPasDecl.h:973
std::vector< Particle_T > resizeBox(const std::array< double, 3 > &boxMin, const std::array< double, 3 > &boxMax)
Resizes the bounding box of the AutoPas object.
Definition: AutoPasImpl.h:218
void setMPITuningMaxDifferenceForBucket(double MPITuningMaxDifferenceForBucket)
Setter for the maximal Difference for the bucket distribution.
Definition: AutoPasDecl.h:1065
const TuningMetricOption & getTuningMetricOption() const
Getter for the tuning metric option.
Definition: AutoPasDecl.h:1036
void setAllowedCellSizeFactors(const NumberSet< double > &allowedCellSizeFactors)
Set allowed cell size factors (only relevant for LinkedCells, VerletLists and VerletListsCells).
Definition: AutoPasDecl.h:624
void forEachInRegion(Lambda forEachLambda, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Execute code on all particles in a certain region as defined by a lambda function.
Definition: AutoPasDecl.h:472
void reduce(Lambda reduceLambda, A &result, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Reduce properties of particles as defined by a lambda function.
Definition: AutoPasDecl.h:365
void setAllowedLoadEstimators(const std::set< LoadEstimatorOption > &allowedLoadEstimators)
Set the list of allowed load estimation algorithms.
Definition: AutoPasDecl.h:841
double getVerletSkin()
Function to iterate over all pairs of particles in the container.
Definition: AutoPasDecl.h:552
void setAoSSortingThreshold(size_t aosSortingThreshold)
Set the aos-sorting-threshold for traversals that use the CellFunctor If the sum of the number of par...
Definition: AutoPasDecl.h:1141
void setAllowedTraversals(const std::set< TraversalOption > &allowedTraversals, const InteractionTypeOption interactionType=InteractionTypeOption::pairwise)
Set the list of allowed traversals.
Definition: AutoPasDecl.h:878
void reduceParallel(Lambda reduceLambda, A &result, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Reduce properties of particles in parallel as defined by a lambda function.
Definition: AutoPasDecl.h:341
void setVerletClusterSize(unsigned int verletClusterSize)
Set Verlet cluster size.
Definition: AutoPasDecl.h:679
void forEach(Lambda forEachLambda, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Execute code on all particles as defined by a lambda function.
Definition: AutoPasDecl.h:327
const std::array< double, 3 > & getBoxMax() const
Get the upper corner of the container without the halo.
Definition: AutoPasImpl.h:331
const NumberSet< double > & getAllowedCellSizeFactors() const
Get allowed cell size factors (only relevant for LinkedCells, VerletLists and VerletListsCells).
Definition: AutoPasDecl.h:618
void addHaloParticle(const Particle_T &haloParticle)
Adds a particle to the container that lies in the halo region of the container.
Definition: AutoPasImpl.h:237
bool searchSpaceIsTrivial() const
get the bool value indicating if the search space is trivial (not more than one configuration to test...
Definition: AutoPasImpl.h:346
void setAllowedDataLayouts(const std::set< DataLayoutOption > &allowedDataLayouts, const InteractionTypeOption interactionType=InteractionTypeOption::pairwise)
Set the list of allowed data layouts.
Definition: AutoPasDecl.h:907
Particle_T ParticleType
Particle type to be accessible after initialization.
Definition: AutoPasDecl.h:52
autopas::ContainerIterator< Particle_T, true, false > IteratorT
Define the iterator type for ease of use.
Definition: AutoPasDecl.h:58
RegionIteratorT getRegionIterator(const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Iterate over all particles in a specified region.
Definition: AutoPasImpl.h:308
void reduceInRegionParallel(Lambda reduceLambda, A &result, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Execute code on all particles in a certain region in parallel as defined by a lambda function.
Definition: AutoPasDecl.h:492
double getMeanRebuildFrequency()
Getter for the mean rebuild frequency.
Definition: AutoPasDecl.h:1107
AutoPas & operator=(AutoPas &&other) noexcept
Move assignment operator.
Definition: AutoPasImpl.h:48
void setExtrapolationMethodOption(ExtrapolationMethodOption extrapolationMethodOption)
Set extrapolation method for the prediction of the configuration performance.
Definition: AutoPasDecl.h:811
void setSoASortingThreshold(size_t soaSortingThreshold)
Set the SoA sorting-threshold.
Definition: AutoPasDecl.h:1154
void setBoxMin(const std::array< double, 3 > &boxMin)
Set coordinates of the lower corner of the domain.
Definition: AutoPasDecl.h:589
void init()
Initialize AutoPas.
Definition: AutoPasImpl.h:55
const std::vector< TuningStrategyOption > & getTuningStrategyOptions() const
Getter for the tuning strategy option.
Definition: AutoPasDecl.h:1019
autopas::ContainerIterator< Particle_T, false, false > ConstIteratorT
Define the const iterator type for ease of use.
Definition: AutoPasDecl.h:64
void forceRetune()
Force the internal tuner to enter a new tuning phase upon the next call to computeInteractions().
Definition: AutoPasImpl.h:232
void setAllowedInteractionTypeOptions(const std::set< InteractionTypeOption > &allowedInteractionTypeOptions)
Set the list of allowed interaction types.
Definition: AutoPasDecl.h:996
void setVerletRebuildFrequency(unsigned int verletRebuildFrequency)
Set Verlet rebuild frequency.
Definition: AutoPasDecl.h:666
void setDeltaT(double deltaT)
Set time step of the simulation.
Definition: AutoPasDecl.h:654
void forEachInRegion(Lambda forEachLambda, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Execute code on all particles in a certain region as defined by a lambda function.
Definition: AutoPasDecl.h:459
const std::set< LoadEstimatorOption > & getAllowedLoadEstimators() const
Get the list of allowed load estimation algorithms.
Definition: AutoPasDecl.h:834
void setUseLOESSSmoothening(bool useLOESSSmoothening)
Set flag for whether a LOESS-based smoothening is used.
Definition: AutoPasDecl.h:722
size_t getNumberOfParticles(IteratorBehavior behavior=IteratorBehavior::owned) const
Returns the number of particles in this container.
Definition: AutoPasImpl.h:140
void reduceInRegionParallel(Lambda reduceLambda, A &result, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Execute code on all particles in a certain region as defined by a lambda function.
Definition: AutoPasDecl.h:506
void deleteAllParticles()
Deletes all particles.
Definition: AutoPasImpl.h:270
bool computeInteractions(Functor *f)
Function to iterate over all inter-particle interactions in the container This function only handles ...
Definition: AutoPasImpl.h:117
void forEachInRegionParallel(Lambda forEachLambda, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Execute code on all particles in a certain region in parallel as defined by a lambda function.
Definition: AutoPasDecl.h:427
void addParticle(const Particle_T &p)
Adds a particle to the container.
Definition: AutoPasImpl.h:180
void forEachInRegionParallel(Lambda forEachLambda, const std::array< double, 3 > &lowerCorner, const std::array< double, 3 > &higherCorner, IteratorBehavior behavior=IteratorBehavior::ownedOrHalo) const
Execute code on all particles in a certain region in parallel as defined by a lambda function.
Definition: AutoPasDecl.h:441
bool getUseLOESSSmoothening() const
Get flag for whether a LOESS-based smoothening is used.
Definition: AutoPasDecl.h:716
double getCutoff() const
Get cutoff radius.
Definition: AutoPasDecl.h:601
IteratorT begin(IteratorBehavior behavior=IteratorBehavior::ownedOrHalo)
Iterate over all particles by using for(auto iter = autoPas.begin(); iter.isValid(); ++iter)
Definition: AutoPasImpl.h:298
size_t getAoSSortingThreshold() const
Get the aos-sorting-threshold for traversals that use the CellFunctor.
Definition: AutoPasDecl.h:1147
std::unordered_map< InteractionTypeOption::Value, std::reference_wrapper< const Configuration > > getCurrentConfigs() const
Getter for the currently selected configuration.
Definition: AutoPasDecl.h:1005
void setRelativeOptimumRange(double relativeOptimumRange)
Set the range for the optimum in which has to be to be tested.
Definition: AutoPasDecl.h:746
void setAllowedContainers(const std::set< ContainerOption > &allowedContainers)
Set the list of allowed containers.
Definition: AutoPasDecl.h:856
void setCutoff(double cutoff)
Set cutoff radius.
Definition: AutoPasDecl.h:607
void setTuningInterval(unsigned int tuningInterval)
Set tuning interval.
Definition: AutoPasDecl.h:691
void setUseSortingThresholdBenchmark(bool useSortingThresholdBenchmark)
Enable or disable benchmark-based AoS/SoA pair-sorting threshold selection.
Definition: AutoPasDecl.h:1169
constexpr bool end() const
Dummy to make range-based for loops work.
Definition: AutoPasDecl.h:394
const std::set< Newton3Option > & getAllowedNewton3Options(const InteractionTypeOption interactionType=InteractionTypeOption::pairwise) const
Get the list of allowed newton 3 options.
Definition: AutoPasDecl.h:924
Public iterator class that iterates over a particle container and additional vectors (which are typic...
Definition: ContainerIterator.h:95
Class representing the different energy sensor options.
Definition: EnergySensorOption.h:19
Functor base class.
Definition: Functor.h:41
double verletSkin
Length added to the cutoff for the Verlet lists' skin.
Definition: LogicHandlerInfo.h:32
std::array< double, 3 > boxMax
Upper corner of the container without halo.
Definition: LogicHandlerInfo.h:24
double deltaT
Time step used in the simulation.
Definition: LogicHandlerInfo.h:47
unsigned int verletClusterSize
Number of particles in a cluster to use in VCL.
Definition: LogicHandlerInfo.h:36
bool useSortingThresholdBenchmark
If true, LogicHandler runs SortingThresholdBenchmark on the first iterate() call and uses the results...
Definition: LogicHandlerInfo.h:42
double cutoff
Cutoff radius to be used in this simulation.
Definition: LogicHandlerInfo.h:28
std::array< double, 3 > boxMin
Lower corner of the container without halo.
Definition: LogicHandlerInfo.h:20
The LogicHandler takes care of the containers s.t.
Definition: LogicHandler.h:50
Virtual class describing a finite or infinite set of numbers.
Definition: NumberSet.h:22
virtual Number getMin() const =0
Get the smallest number in the set.
virtual std::unique_ptr< NumberSet > clone() const =0
Create a copy of a NumberSet.
The ParticleContainerInterface class provides a basic interface for all Containers within AutoPas.
Definition: ParticleContainerInterface.h:40
Class representing the load estimator choices.
Definition: TuningMetricOption.h:18
static void exception(const Exception e)
Handle an exception derived by std::exception.
Definition: ExceptionHandler.h:64
This is the main namespace of AutoPas.
Definition: AutoPasDecl.h:34
decltype(auto) withStaticContainerType(ParticleContainerInterface< Particle_T > &container, FunctionType &&function)
Will execute the passed function body with the static container type of container.
Definition: StaticContainerSelector.h:35
int AutoPas_MPI_Comm_free(AutoPas_MPI_Comm *comm)
Wrapper for MPI_Comm_free.
Definition: WrapMPI.h:820
unsigned int tuningInterval
Number of time steps after which the auto-tuner shall reevaluate the optimum.
Definition: AutoTunerInfo.h:29
SelectorStrategyOption selectorStrategy
Strategy how to select the optimum from the collected samples.
Definition: AutoTunerInfo.h:21
size_t soaSortingThreshold
Default number of particles in two SoA buffers from which SoA sorting should be performed,...
Definition: AutoTunerInfo.h:60
unsigned int maxSamples
Number of samples that shall be collected per combination.
Definition: AutoTunerInfo.h:33
bool useLOESSSmoothening
Flag for whether LOESS Smoothening is used to smoothen the tuning results.
Definition: AutoTunerInfo.h:46
TuningMetricOption tuningMetric
Metric used to rate configurations (time or energy).
Definition: AutoTunerInfo.h:25
size_t aosSortingThreshold
Default number of particles in two cells from which AoS sorting should be performed,...
Definition: AutoTunerInfo.h:53
double earlyStoppingFactor
EarlyStoppingFactor for the auto-tuner.
Definition: AutoTunerInfo.h:38
EnergySensorOption energySensor
Used energy sensor of energy metric selected.
Definition: AutoTunerInfo.h:42
Helper struct encapsulating most information needed to build TuningStrategies by the TuningStrategyFa...
Definition: TuningStrategyFactoryInfo.h:21
double mpiTuningWeightForMaxDensity
Weight for maxDensity in the calculation for bucket distribution.
Definition: TuningStrategyFactoryInfo.h:76
double mpiTuningMaxDifferenceForBucket
Maximum absolute difference in similarity metric for two ranks to fall in the same bucket.
Definition: TuningStrategyFactoryInfo.h:72
std::string ruleFileName
The name and path of the file where the rules are stored.
Definition: TuningStrategyFactoryInfo.h:55
unsigned int maxEvidence
Strategies that don't converge (or not quickly enough) can be told to limit the number of evidence to...
Definition: TuningStrategyFactoryInfo.h:26
std::string fuzzyRuleFileName
The name and path of the file where the rules are stored.
Definition: TuningStrategyFactoryInfo.h:61
unsigned int maxTuningPhasesWithoutTest
If a config is not tested for this number of tuning phases test it again to make predictions more rel...
Definition: TuningStrategyFactoryInfo.h:39
double relativeBlacklistRange
Any configuration that is slower than the fastest times this factor will be blacklisted.
Definition: TuningStrategyFactoryInfo.h:49
ExtrapolationMethodOption extrapolationMethodOption
Function option used for extrapolating performance from observed evidence.
Definition: TuningStrategyFactoryInfo.h:31
double relativeOptimumRange
Factor of the range of the optimal configurations for the optimalSearchSpace.
Definition: TuningStrategyFactoryInfo.h:35
unsigned int minNumberOfEvidence
The number of evidence that have to be collected until the first prediction can be made.
Definition: TuningStrategyFactoryInfo.h:43
AutoPas_MPI_Comm autopasMpiCommunicator
MPI Communicator used within AutoPas.
Definition: TuningStrategyFactoryInfo.h:80