91 #ifndef vtk_m_worklet_contourtree_distributed_hierarchical_augmenter_h
92 #define vtk_m_worklet_contourtree_distributed_hierarchical_augmenter_h
122 namespace contourtree_distributed
126 template <
typename FieldType>
236 std::string
DebugPrint(std::string message,
const char* fileName,
long lineNum);
248 template <
typename FieldType>
255 this->BlockId = blockId;
256 this->BaseTree = baseTree;
257 this->AugmentedTree = augmentedTree;
266 isAttachementPointPredicate(
267 this->BaseTree->Superarcs, this->BaseTree->WhichRound, this->BaseTree->NumRounds);
268 auto tempSupernodeIndex =
282 isAttachementPointPredicate);
286 this->GlobalRegularIds.Allocate(this->AttachmentIds.GetNumberOfValues());
287 this->DataValues.Allocate(this->AttachmentIds.GetNumberOfValues());
288 this->SupernodeIds.Allocate(this->AttachmentIds.GetNumberOfValues());
289 this->Superparents.Allocate(this->AttachmentIds.GetNumberOfValues());
290 this->SuperparentRounds.Allocate(this->AttachmentIds.GetNumberOfValues());
291 this->WhichRounds.Allocate(this->AttachmentIds.GetNumberOfValues());
295 auto hierarchicalRegularIds =
301 hierarchicalRegularIds, BaseTree->RegularNodeGlobalIds),
302 this->GlobalRegularIds);
313 this->SuperparentRounds);
332 this->BaseTree->Superarcs);
337 this->AttachmentIds.ReleaseResources();
343 template <
typename FieldType>
347 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
348 IsAttachementPointNeededPredicate isAttachementPointNeededPredicate(
349 this->SuperparentRounds, this->WhichRounds, round);
350 auto tempAttachmentPointsIndex =
354 tempAttachmentPointsIndex,
356 tempAttachmentPointsIndex,
361 isAttachementPointNeededPredicate);
372 this->OutData.GlobalRegularIds);
376 this->OutData.DataValues);
380 this->OutData.SupernodeIds);
384 this->OutData.Superparents);
388 this->OutData.SuperparentRounds);
392 this->OutData.WhichRounds);
396 this->AttachmentIds.ReleaseResources();
401 template <
typename FieldType>
407 vtkm::Id numAttachmentsCurrently = this->GlobalRegularIds.GetNumberOfValues();
408 vtkm::Id numIncomingAttachments = InData.GlobalRegularIds.GetNumberOfValues();
409 vtkm::Id numTotalAttachments = numAttachmentsCurrently + numIncomingAttachments;
412 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
413 this->GlobalRegularIds, numTotalAttachments,
static_cast<vtkm::Id>(0));
414 vtkm::worklet::contourtree_augmented::ResizeVector<FieldType>(
415 this->DataValues, numTotalAttachments,
static_cast<FieldType
>(0));
416 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
417 this->SupernodeIds, numTotalAttachments,
static_cast<vtkm::Id>(0));
418 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
419 this->Superparents, numTotalAttachments,
static_cast<vtkm::Id>(0));
420 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
421 this->SuperparentRounds, numTotalAttachments,
static_cast<vtkm::Id>(0));
422 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
423 this->WhichRounds, numTotalAttachments,
static_cast<vtkm::Id>(0));
438 this->GlobalRegularIds, numAttachmentsCurrently, numIncomingAttachments);
442 this->DataValues, numAttachmentsCurrently, numIncomingAttachments);
448 this->SupernodeIds, numAttachmentsCurrently, numIncomingAttachments);
452 this->Superparents, numAttachmentsCurrently, numIncomingAttachments);
456 this->SuperparentRounds, numAttachmentsCurrently, numIncomingAttachments);
460 this->WhichRounds, numAttachmentsCurrently, numIncomingAttachments);
467 template <
typename FieldType>
470 this->OutData.ReleaseResources();
471 this->InData.ReleaseResources();
476 template <
typename FieldType>
480 this->PrepareAugmentedTree();
482 this->CopyHyperstructure();
484 this->CopySuperstructure();
486 this->UpdateHyperstructure();
488 this->CopyBaseRegularStructure();
493 template <
typename FieldType>
506 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
507 AttachmentSuperparentAndIndexComparator attachmentSuperparentAndIndexComparator(
508 this->SuperparentRounds, this->GlobalRegularIds, this->SupernodeIds);
512 attachmentIdsEqualComparator(this->GlobalRegularIds);
521 this->BaseTree->NumRounds + 2),
522 this->FirstAttachmentPointInRound);
526 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
527 SetFirstAttachmentPointInRoundWorklet setFirstAttachmentPointInRoundWorklet;
528 this->Invoke(setFirstAttachmentPointInRoundWorklet,
530 this->SuperparentRounds,
531 this->FirstAttachmentPointInRound);
537 auto firstAttachmentPointInRoundPortal = this->FirstAttachmentPointInRound.WritePortal();
538 firstAttachmentPointInRoundPortal.Set(this->BaseTree->NumRounds + 1,
539 this->AttachmentIds.GetNumberOfValues());
543 this->DebugPrint(
"First Attachment Point Set Where Possible", __FILE__, __LINE__));
548 for (
vtkm::Id roundNumber = this->BaseTree->NumRounds; roundNumber >= 0; roundNumber--)
552 firstAttachmentPointInRoundPortal.Get(roundNumber)))
554 firstAttachmentPointInRoundPortal.Set(roundNumber,
555 firstAttachmentPointInRoundPortal.Get(roundNumber + 1));
565 this->BaseTree->Supernodes.GetNumberOfValues()),
566 this->NewSupernodeIds);
570 this->DebugPrint(
"Augmented Tree Prepared", __FILE__, __LINE__));
577 template <
typename FieldType>
581 this->AugmentedTree->NumRounds = this->BaseTree->NumRounds;
584 static_cast<vtkm::Id>(0), this->BaseTree->NumRegularNodesInRound.GetNumberOfValues()),
585 this->AugmentedTree->NumRegularNodesInRound);
588 static_cast<vtkm::Id>(0), this->BaseTree->NumSupernodesInRound.GetNumberOfValues()),
589 this->AugmentedTree->NumSupernodesInRound);
592 this->AugmentedTree->FirstSupernodePerIteration.resize(
593 this->BaseTree->FirstSupernodePerIteration.size());
596 roundNumber < static_cast<vtkm::Id>(this->AugmentedTree->FirstSupernodePerIteration.size());
602 this->BaseTree->FirstSupernodePerIteration[roundNumber].GetNumberOfValues()),
603 this->AugmentedTree->FirstSupernodePerIteration[roundNumber]);
608 this->AugmentedTree->NumHypernodesInRound);
610 this->AugmentedTree->FirstHypernodePerIteration.resize(
611 this->BaseTree->FirstHypernodePerIteration.size());
614 roundNumber < static_cast<vtkm::Id>(this->AugmentedTree->FirstHypernodePerIteration.size());
619 this->AugmentedTree->FirstHypernodePerIteration[roundNumber]);
629 template <
typename FieldType>
634 for (
vtkm::Id roundNumber = this->BaseTree->NumRounds; roundNumber >= 0; roundNumber--)
637 this->RetrieveOldSupernodes(roundNumber);
640 this->ResizeArrays(roundNumber);
642 this->CreateSuperarcs(roundNumber);
646 this->DebugPrint(
"Superstructure Copied", __FILE__, __LINE__));
652 template <
typename FieldType>
659 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
660 UpdateHyperstructureSetHyperarcsAndNodesWorklet
661 updateHyperstructureSetHyperarcsAndNodesWorklet;
663 updateHyperstructureSetHyperarcsAndNodesWorklet,
664 this->BaseTree->Hypernodes,
665 this->BaseTree->Hyperarcs,
666 this->NewSupernodeIds,
667 this->AugmentedTree->Hypernodes,
668 this->AugmentedTree->Hyperarcs
675 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
676 UpdateHyperstructureSetSuperchildrenWorklet updateHyperstructureSetSuperchildrenWorklet(
677 this->AugmentedTree->Supernodes.GetNumberOfValues());
679 updateHyperstructureSetSuperchildrenWorklet,
680 this->AugmentedTree->Hypernodes,
681 this->AugmentedTree->Superchildren
688 template <
typename FieldType>
694 this->AugmentedTree->RegularNodeSortOrder);
697 permuteComparator(this->AugmentedTree->RegularNodeGlobalIds);
703 DebugPrint(
"Regular Node Sorter Sorted", __FILE__, __LINE__));
726 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
727 FindSuperparentForNecessaryNodesWorklet findSuperparentForNecessaryNodesWorklet;
729 auto findRegularByGlobal = this->AugmentedTree->GetFindRegularByGlobal();
730 auto findSuperArcForUnknownNode = this->AugmentedTree->GetFindSuperArcForUnknownNode();
733 this->Invoke(findSuperparentForNecessaryNodesWorklet,
735 this->BaseTree->RegularNodeGlobalIds,
736 this->BaseTree->Superparents,
737 this->BaseTree->DataValues,
738 this->BaseTree->Superarcs,
739 this->NewSupernodeIds,
742 findSuperArcForUnknownNode,
744 this->RegularSuperparents,
745 tempRegularNodesNeeded
751 tempRegularNodesNeeded,
752 tempRegularNodesNeeded,
753 this->RegularNodesNeeded,
754 notNoSuchElementPredicate
759 vtkm::Id numRegNeeded = this->RegularNodesNeeded.GetNumberOfValues();
760 vtkm::Id numExistingRegular = this->AugmentedTree->RegularNodeGlobalIds.GetNumberOfValues();
761 vtkm::Id numTotalRegular = numExistingRegular + numRegNeeded;
764 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
765 this->AugmentedTree->RegularNodeGlobalIds, numTotalRegular,
static_cast<vtkm::Id>(0));
766 vtkm::worklet::contourtree_augmented::ResizeVector<FieldType>(
767 this->AugmentedTree->DataValues, numTotalRegular,
static_cast<FieldType
>(0));
768 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
769 this->AugmentedTree->RegularNodeSortOrder, numTotalRegular,
static_cast<vtkm::Id>(0));
770 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
771 this->AugmentedTree->Regular2Supernode,
774 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
775 this->AugmentedTree->Superparents, numTotalRegular,
static_cast<vtkm::Id>(0));
781 copyBaseRegularStructureWorklet(numExistingRegular);
787 auto regularNodesNeededRange =
791 this->RegularNodesNeeded, this->BaseTree->RegularNodeGlobalIds);
793 auto baseTreeDataValuesPermuted =
796 auto regularSuperparentsPermuted =
799 auto augmentedTreeRegularNodeGlobalIdsView =
804 auto augmentedTreeDataValuesView =
809 auto augmentedTreeSuperparentsView =
814 auto augmentedTreeRegularNodeSortOrderView =
818 this->Invoke(copyBaseRegularStructureWorklet,
819 regularNodesNeededRange,
820 baseTreeRegularNodeGlobalIdsPermuted,
821 baseTreeDataValuesPermuted,
822 regularSuperparentsPermuted,
823 augmentedTreeRegularNodeGlobalIdsView,
824 augmentedTreeDataValuesView,
825 augmentedTreeSuperparentsView,
826 augmentedTreeRegularNodeSortOrderView
833 permuteComparator(this->AugmentedTree->RegularNodeGlobalIds);
841 template <
typename FieldType>
854 this->BaseTree->NumSupernodesInRound.ReadPortal().Get(roundNumber));
857 if (!(roundNumber < this->BaseTree->NumRounds))
870 this->BaseTree->NumSupernodesInRound.ReadPortal().Get(roundNumber)),
872 this->KeptSupernodes);
881 this->BaseTree->Superarcs, supernodeIndexBase, this->KeptSupernodes.GetNumberOfValues()),
884 this->KeptSupernodes,
889 notNoSuchElementPredicate);
894 DebugPrint(std::string(
"Round ") + std::to_string(roundNumber) +
895 std::string(
" Old Supernodes Retrieved"),
903 template <
typename FieldType>
911 vtkm::Id numSupernodesAlready = this->AugmentedTree->Supernodes.GetNumberOfValues();
916 numInsertedSupernodes + this->KeptSupernodes.GetNumberOfValues();
917 vtkm::Id newSupernodeCount = numSupernodesAlready + numSupernodesThisLevel;
921 roundNumber, numSupernodesThisLevel, this->AugmentedTree->NumRegularNodesInRound);
923 roundNumber, numSupernodesThisLevel, this->AugmentedTree->NumSupernodesInRound);
925 0, numSupernodesAlready, this->AugmentedTree->FirstSupernodePerIteration[roundNumber]);
932 this->AugmentedTree->Supernodes,
936 this->AugmentedTree->Supernodes,
940 this->AugmentedTree->Superarcs,
944 this->AugmentedTree->Hyperparents,
948 this->AugmentedTree->Super2Hypernode,
952 this->AugmentedTree->WhichRound,
956 this->AugmentedTree->WhichIteration,
964 this->AugmentedTree->RegularNodeGlobalIds,
967 vtkm::worklet::contourtree_augmented::ResizeVector<FieldType>(
968 this->AugmentedTree->DataValues, newSupernodeCount,
static_cast<FieldType
>(0));
970 this->AugmentedTree->Regular2Supernode,
974 this->AugmentedTree->Superparents,
982 DebugPrint(std::string(
"Round ") + std::to_string(roundNumber) + std::string(
" Arrays Resized"),
992 this->SupernodeSorter);
994 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
995 this->GlobalRegularIdSet, numSupernodesThisLevel,
static_cast<vtkm::Id>(0));
996 vtkm::worklet::contourtree_augmented::ResizeVector<FieldType>(
997 this->DataValueSet, numSupernodesThisLevel,
static_cast<FieldType
>(0));
998 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
999 this->SuperparentSet, numSupernodesThisLevel,
static_cast<vtkm::Id>(0));
1000 vtkm::worklet::contourtree_augmented::ResizeVector<vtkm::Id>(
1001 this->SupernodeIdSet, numSupernodesThisLevel,
static_cast<vtkm::Id>(0));
1005 DebugPrint(std::string(
"Round ") + std::to_string(roundNumber) +
1006 std::string(
" Sorter Set Resized"),
1014 vtkm::Id firstAttachmentPointInRoundCurrent =
1016 vtkm::Id firstAttachmentPointInRoundNext =
1018 vtkm::Id currRange = firstAttachmentPointInRoundNext - firstAttachmentPointInRoundCurrent;
1019 auto attachmentPointIdView =
1021 firstAttachmentPointInRoundCurrent,
1024 auto globalRegularIdsPermuted =
1026 this->GlobalRegularIds
1028 auto dataValuesPermuted =
1030 auto superparentsPermuted =
1032 auto supernodeIdsPermuted =
1038 globalRegularIdsPermuted,
1040 globalRegularIdsPermuted.GetNumberOfValues(),
1042 this->GlobalRegularIdSet,
1045 dataValuesPermuted, 0, dataValuesPermuted.GetNumberOfValues(), this->DataValueSet, 0);
1047 superparentsPermuted, 0, superparentsPermuted.GetNumberOfValues(), this->SuperparentSet, 0);
1049 supernodeIdsPermuted, 0, supernodeIdsPermuted.GetNumberOfValues(), this->SupernodeIdSet, 0);
1054 DebugPrint(std::string(
"Round ") + std::to_string(roundNumber) +
1055 std::string(
" Attachment Points Transferred"),
1062 auto oldRegularIdArr =
1064 this->BaseTree->Supernodes);
1067 oldRegularIdArr, this->BaseTree->RegularNodeGlobalIds);
1068 auto baseTreeDataValuesPermuted =
1075 baseTreeregularNodeGlobalIdsPermuted.GetNumberOfValues(),
1076 this->GlobalRegularIdSet,
1077 numInsertedSupernodes);
1080 baseTreeDataValuesPermuted.GetNumberOfValues(),
1082 numInsertedSupernodes);
1085 this->KeptSupernodes.GetNumberOfValues(),
1086 this->SupernodeIdSet,
1087 numInsertedSupernodes);
1092 this->KeptSupernodes.GetNumberOfValues(),
1094 this->KeptSupernodes,
1095 this->BaseTree->Superarcs);
1098 this->KeptSupernodes.GetNumberOfValues(),
1099 this->SuperparentSet,
1100 numInsertedSupernodes);
1105 DebugPrint(std::string(
"Round ") + std::to_string(roundNumber) +
1106 std::string(
" Kept Supernodes Transferred"),
1113 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
1114 AttachmentAndSupernodeComparator<FieldType>
1115 attachmentAndSupernodeComparator(
1116 this->SuperparentSet, this->DataValueSet, this->GlobalRegularIdSet);
1122 DebugPrint(std::string(
"Round ") + std::to_string(roundNumber) +
1123 std::string(
" Sorter Set Sorted"),
1130 vtkm::worklet::contourtree_distributed::hierarchical_augmenter::
1131 ResizeArraysBuildNewSupernodeIdsWorklet resizeArraysBuildNewSupernodeIdsWorklet(
1132 numSupernodesAlready);
1134 auto supernodeIdSetPermuted =
1137 resizeArraysBuildNewSupernodeIdsWorklet,
1139 supernodeIdSetPermuted,
1147 DebugPrint(std::string(
"Round ") + std::to_string(roundNumber) +
1148 std::string(
" Sorting Arrays Built"),
1156 template <
typename FieldType>
1180 numSupernodesAlready,
1182 this->SupernodeSorter.GetNumberOfValues()
1184 auto newRegularId = newSupernodeId;
1186 auto permutedSuperparentSet =
1192 auto permutedAugmentedTreeSupernodes =
1200 createSuperarcsWorklet(
1201 numSupernodesAlready,
1202 this->BaseTree->NumRounds,
1205 this->AugmentedTree->Supernodes.GetNumberOfValues());
1207 auto permutedGlobalRegularIdSet =
1209 auto augmentedTreeSuperarcsView =
1211 numSupernodesAlready,
1212 this->SupernodeSorter.GetNumberOfValues());
1213 auto augmentedTreeSuper2HypernodeView =
1215 numSupernodesAlready,
1216 this->SupernodeSorter.GetNumberOfValues());
1218 this->Invoke(createSuperarcsWorklet,
1219 this->SupernodeSorter,
1220 this->SuperparentSet,
1221 this->BaseTree->Superarcs,
1222 this->NewSupernodeIds,
1223 this->BaseTree->Supernodes,
1224 this->BaseTree->RegularNodeGlobalIds,
1225 permutedGlobalRegularIdSet,
1226 this->BaseTree->Super2Hypernode,
1227 this->BaseTree->WhichIteration,
1228 augmentedTreeSuperarcsView,
1229 this->AugmentedTree->FirstSupernodePerIteration[roundNumber],
1230 augmentedTreeSuper2HypernodeView
1237 auto permutedAugmentedTreeHyperparents =
1239 auto permutedBaseTreeHyperparents =
1245 auto permutedAugmentedTreeWhichRound =
1247 auto permutedBaseTreeWhichRound =
1252 auto permutedAugmentedTreeWhichIteration =
1255 superparentOldSuperId, this->BaseTree->WhichIteration);
1257 permutedAugmentedTreeWhichIteration);
1263 newRegularId, this->AugmentedTree->RegularNodeGlobalIds);
1264 auto permutedGlobalRegularIdSet =
1267 permutedAugmentedTreeRegularNodeGlobalIds);
1269 auto permutedAugmentedTreeDataValues =
1271 auto permutedDataValueSet =
1279 auto permutedAugmentedTreeRegular2Supernode =
1285 auto permutedAugmentedTreeSuperparents =
1296 if (iterationArraySize > 0)
1298 vtkm::Id lastSupernodeThisLevel = this->AugmentedTree->Supernodes.GetNumberOfValues() - 1;
1302 if (lastIterationThisLevel < iterationArraySize - 1)
1306 roundNumber, iterationArraySize - 1, this->AugmentedTree->NumIterations);
1308 this->AugmentedTree->FirstSupernodePerIteration[roundNumber].Allocate(
1311 iterationArraySize - 1,
1312 this->AugmentedTree->Supernodes.GetNumberOfValues(),
1313 this->AugmentedTree->FirstSupernodePerIteration[roundNumber]);
1316 this->AugmentedTree->FirstHypernodePerIteration[roundNumber].Allocate(
1323 this->SupernodeSorter.ReleaseResources();
1324 this->GlobalRegularIdSet.ReleaseResources();
1325 this->DataValueSet.ReleaseResources();
1326 this->SuperparentSet.ReleaseResources();
1327 this->SupernodeIdSet.ReleaseResources();
1332 template <
typename FieldType>
1334 const char* fileName,
1337 std::stringstream resultStream;
1338 resultStream << std::endl;
1339 resultStream <<
"----------------------------------------" << std::endl;
1340 resultStream << std::setw(30) << std::left << fileName <<
":" << std::right << std::setw(4)
1341 << lineNum << std::endl;
1342 resultStream <<
"Block " << std::setw(4) << this->BlockId <<
": " << std::left << message
1344 resultStream <<
"----------------------------------------" << std::endl;
1346 resultStream << this->BaseTree->DebugPrint(
1347 (message + std::string(
" Base Tree")).c_str(), fileName, lineNum);
1348 resultStream << this->AugmentedTree->DebugPrint(
1349 (message + std::string(
" Augmented Tree")).c_str(), fileName, lineNum);
1350 resultStream <<
"========================================" << std::endl;
1351 resultStream <<
"Local List of Attachment Points" << std::endl;
1354 "Global Regular Ids", this->GlobalRegularIds, -1, resultStream);
1356 "Data Values", this->DataValues, -1, resultStream);
1358 "Supernode Ids", this->SupernodeIds, -1, resultStream);
1360 "Superparents", this->Superparents, -1, resultStream);
1362 "Superparent Rounds", this->SuperparentRounds, -1, resultStream);
1364 "WhichRounds", this->WhichRounds, -1, resultStream);
1365 resultStream << std::endl;
1366 resultStream <<
"Outgoing Attachment Points" << std::endl;
1368 this->OutData.GlobalRegularIds.GetNumberOfValues());
1370 "Out Global Regular Ids", this->OutData.GlobalRegularIds, -1, resultStream);
1372 "Out Data Values", this->OutData.DataValues, -1, resultStream);
1374 "Out Supernode Ids", this->OutData.SupernodeIds, -1, resultStream);
1376 "Out Superparents", this->OutData.Superparents, -1, resultStream);
1378 "Out Superparent Rounds", this->OutData.SuperparentRounds, -1, resultStream);
1380 "Out WhichRounds", this->OutData.WhichRounds, -1, resultStream);
1381 resultStream << std::endl;
1382 resultStream <<
"Incoming Attachment Points" << std::endl;
1384 this->InData.GlobalRegularIds.GetNumberOfValues());
1386 "In Global Regular Ids", this->InData.GlobalRegularIds, -1, resultStream);
1388 "In Data Values", this->InData.DataValues, -1, resultStream);
1390 "In Supernode Ids", this->InData.SupernodeIds, -1, resultStream);
1392 "In Superparents", this->InData.Superparents, -1, resultStream);
1394 "In Superparent Rounds", this->InData.SuperparentRounds, -1, resultStream);
1396 "In WhichRounds", this->InData.WhichRounds, -1, resultStream);
1397 resultStream << std::endl;
1398 resultStream <<
"Holding Arrays" << std::endl;
1400 this->FirstAttachmentPointInRound.GetNumberOfValues());
1402 "First Attach / Rd", this->FirstAttachmentPointInRound, -1, resultStream);
1405 "AttachmentIds", this->AttachmentIds, -1, resultStream);
1408 "New Supernode Ids", this->NewSupernodeIds, -1, resultStream);
1411 "Kept Supernodes", this->KeptSupernodes, -1, resultStream);
1414 "Supernode Sorter", this->SupernodeSorter, -1, resultStream);
1416 "Global Regular Id", this->GlobalRegularIdSet, -1, resultStream);
1418 "Data Values", this->DataValueSet, -1, resultStream);
1420 "Superparents", this->SuperparentSet, -1, resultStream);
1422 "SupernodeIds", this->SupernodeIdSet, -1, resultStream);
1423 resultStream << std::endl;
1424 resultStream << std::endl;
1428 "Supernode Id", this->SupernodeSorter, -1, resultStream);
1430 "Permuted Superparent",
1440 "Permuted Global Id",
1445 "Permuted Supernode Id",
1449 resultStream << std::endl;
1450 resultStream << std::endl;
1454 "RegularNodesNeeded", this->RegularNodesNeeded, -1, resultStream);
1456 "RegularSuperparents", this->RegularSuperparents, -1, resultStream);
1457 resultStream << std::endl;
1465 return resultStream.str();
1470 template <
typename FieldType>
1473 std::ofstream outstream(filename);
1474 outstream <<
"Augmented Tree:" << std::endl;
1477 0, this->AugmentedTree->Supernodes.GetNumberOfValues()),
1479 std::string dumpVolumesString =
1481 this->AugmentedTree->Supernodes,
1482 this->AugmentedTree->Superarcs,
1483 this->AugmentedTree->RegularNodeGlobalIds,
1487 outstream << dumpVolumesString;
1489 "Global Regular IDs", this->GlobalRegularIds, -1, outstream);
1492 "Supernode IDs", this->SupernodeIds, -1, outstream);
1494 "Superparents", this->Superparents, -1, outstream);
1496 "Superparent Rounds", this->SuperparentRounds, -1, outstream);
1498 "WhichRounds", this->WhichRounds, -1, outstream);
1500 "Out Global Regular IDs", this->OutData.GlobalRegularIds, -1, outstream);
1502 "Out Data Values", this->OutData.DataValues, -1, outstream);
1504 "Out Supernode IDs", this->OutData.SupernodeIds, -1, outstream);
1506 "Out Superparents", this->OutData.Superparents, -1, outstream);
1508 "Out Superparent Rounds", this->OutData.SuperparentRounds, -1, outstream);
1510 "Out WhichRounds", this->OutData.WhichRounds, -1, outstream);
1512 "In Global Regular IDs", this->InData.GlobalRegularIds, -1, outstream);
1514 "In Data Values", this->InData.DataValues, -1, outstream);
1516 "In Supernode IDs", this->InData.SupernodeIds, -1, outstream);
1518 "In Superparents", this->InData.Superparents, -1, outstream);
1520 "In Superparent Rounds", this->InData.SuperparentRounds, -1, outstream);
1522 "In WhichRounds", this->InData.WhichRounds, -1, outstream);
1524 "First Attach / Rd", this->FirstAttachmentPointInRound, -1, outstream);
1526 "AttachmentIDs", this->AttachmentIds, -1, outstream);
1528 "New Supernode IDs", this->NewSupernodeIds, -1, outstream);
1530 "Kept Supernodes", this->KeptSupernodes, -1, outstream);
1532 "Supernode Sorter", this->SupernodeSorter, -1, outstream);
1534 "Global Regular ID", this->GlobalRegularIdSet, -1, outstream);
1536 "Data Values", this->DataValueSet, -1, outstream);
1538 "Superparents", this->SuperparentSet, -1, outstream);
1540 "SupernodeIDs", this->SupernodeIdSet, -1, outstream);
1542 "Supernode ID", this->SupernodeSorter, -1, outstream);
1544 "Permuted Superparent",
1554 "Permuted Global ID",
1559 "Permuted Supernode ID",
1564 "RegularNodesNeeded", this->RegularNodesNeeded, -1, outstream);
1566 "RegularSuperparents", this->RegularSuperparents, -1, outstream);