From: Multi-label literature classification based on the Gene Ontology graph
1 | inputs |
---|---|
d, a new document | |
G, a GO graph with trained base-classifiers | |
2 | initialize: |
3 | PA ← {root} //Predicted GO annotation set |
4 | Q ← {root} //Queue for breadth first search |
5 | while Q not empty |
6 | n ← Q.pop() |
7 | S ← G.children(n) |
8 | for each c in S: |
9 | y ← c.predict (d) |
//Classify d using the base-classifier of c | |
10 | if y == 1: |
//if prediction is positive | |
11 | Q ← union(Q, c) |
12 | PA ← union(PA, c) |
13 | end |
14 | end |
15 | outputs: PA |