Skip to content

Commit

Permalink
add number of detonations to statistics export
Browse files Browse the repository at this point in the history
  • Loading branch information
chrxh committed Oct 28, 2023
1 parent 4f48055 commit 120cdfe
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions source/EngineInterface/ExportService.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ bool ExportService::exportCollectedStatistics(std::vector<DataPointCollection> c
writeLabelAllColors("Sensor matches");
writeLabelAllColors("Reconnector creations");
writeLabelAllColors("Reconnector deletions");
writeLabelAllColors("Detonations");

file << std::endl;

auto writeIntValueAllColors = [&file](DataPoint const& dataPoint) {
Expand Down Expand Up @@ -72,6 +74,7 @@ bool ExportService::exportCollectedStatistics(std::vector<DataPointCollection> c
writeDoubleValueAllColors(dataPointCollection.numSensorMatches);
writeDoubleValueAllColors(dataPointCollection.numReconnectorCreated);
writeDoubleValueAllColors(dataPointCollection.numReconnectorRemoved);
writeDoubleValueAllColors(dataPointCollection.numDetonations);
file << std::endl;
}
file.close();
Expand Down Expand Up @@ -110,6 +113,9 @@ bool ExportService::exportStatistics(uint64_t timestep, StatisticsData const& st
writeLabelAllColors("Neuron activities");
writeLabelAllColors("Sensor activities");
writeLabelAllColors("Sensor matches");
writeLabelAllColors("Reconnector creations");
writeLabelAllColors("Reconnector deletions");
writeLabelAllColors("Detonations");
file << std::endl;

auto writeIntValueAllColors = [&file](ColorVector<int> const& values) {
Expand Down Expand Up @@ -146,6 +152,10 @@ bool ExportService::exportStatistics(uint64_t timestep, StatisticsData const& st
writeInt64ValueAllColors(statisticsData.timeline.accumulated.numNeuronActivities);
writeInt64ValueAllColors(statisticsData.timeline.accumulated.numSensorActivities);
writeInt64ValueAllColors(statisticsData.timeline.accumulated.numSensorMatches);
writeInt64ValueAllColors(statisticsData.timeline.accumulated.numReconnectorCreated);
writeInt64ValueAllColors(statisticsData.timeline.accumulated.numReconnectorRemoved);
writeInt64ValueAllColors(statisticsData.timeline.accumulated.numDetonations);

file << std::endl;
file.close();
return true;
Expand Down

0 comments on commit 120cdfe

Please sign in to comment.