Skip to content

Commit

Permalink
#1382: add union in StatisticQuantityMap
Browse files Browse the repository at this point in the history
  • Loading branch information
stmcgovern committed Jul 19, 2022
1 parent 7209641 commit e4f1dec
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/vt/vrt/collection/balance/lb_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,12 @@ enum struct Statistic : int8_t {
// InternalEdgesCardinality
};

using StatisticQuantityMap = std::map<StatisticQuantity, double>;
using UnionValueType = vt::adt::SafeUnion<
double,
adt::HistogramApprox<double, int64_t>
>;

using StatisticQuantityMap = std::map<StatisticQuantity, UnionValueType>;
using StatisticMap = std::unordered_map<Statistic, StatisticQuantityMap>;

nlohmann::json jsonifyPhaseStatistics(const StatisticMap &statistics);
Expand Down

0 comments on commit e4f1dec

Please sign in to comment.