Algorithm 3.
Minimizer-space POA graph construction and consensus generation
Input: A query ordered list of minimizers q to be error-corrected, collection of query neighbors N | ||
1: | procedure POA(q, N) | |
2: | G = (V,E) ← initializeGraph(q) | ▹ As described in (Lee et al., 2002) |
3: | for n∈N do | |
4: | G ← semiGlobalAlign(G,n) | ▹ As described in (Lee et al., 2002) |
5: | end for | |
6: | λ ← {} | ▹ Scoring table for nodes |
7: | P ← {} | ▹ Predecessor table for nodes |
8: | topologicalSort(G) | ▹ Topological sorting of nodes |
9: | for v∈V do | |
10: | e = (u, v) ← max(inEdges(v)) | ▹ Find the maximum-weighted incoming edge to v |
11: | λ[v] ← We + λ[u] | |
12: | P[v] ← u | |
13: | end for | |
14: | C ← CONSENSUS(V, λ; P) | ▹ Described in the “Minimizer-space POA” |
Section | ||
15: | return C | |
16: | end procedure |