Topological Sort
Start Menu Path: Project Explorer Menu / Configuration Mgt / Topological Sort
Function:
- The "Topological Sort" script sorts a TagList into groups by its linking structure.
- The term "topological sort" refers to the type of algorithm used: to sort a directed graph, order the vertices such that for every directed edge 'uv' from vertex 'u'
to vertex 'v', 'u' comes before 'v' in the ordering. This implementation orders the vertices in groups that can be copied and linked (i.e. branched) in series.
- In more simple terms, this is the tool to help sort large data sets into manageable branch groups by their link structure.
Instructions:
- The script starts by invoking the Edit TagList dialog. Select modules or load a TagList, then press the Use selected modules button.

- A small dialog will appear:

- Press the Full Data Set button to see all the internally generated lists for the topological sort.
- Press the Only Final Groups button to see only the sorted groups of modules.
- The progress bar will appear. Press the Abort button to quit the processing.

- When the script is done processing, another dialog will appear with the sorted groups of modules.

- Those in the first group have no out-links to any modules in the original input list.
- Those in the second group have out-links only to modules outside the original input list or to modules in the first group.
- Those in the third group have out-links only to modules outside the original input list or to modules in the second group.
- Etc...
- If the last line says "Unbreakable", that means the last group is interlinked, i.e. there are loops or cycles in the linking. What this means for branching:
- Groups must be branched in order.
- Any group but the last can be branched in pieces, i.e. the group can be broken into subgroups that can be branched in any order or in parallel.
- The last group,
- if "Unbreakable", must be branched in one operation, since there is a loop.
- else the last group can also be broken into subgroups.
- Press the Save Results to TagLists button to save each group to a separate TagList.