Package org.apache.sysds.lops.compile
Class LopComparator<N extends Lop>
java.lang.Object
org.apache.sysds.lops.compile.LopComparator<N>
- Type Parameters:
N- class extending Lop
- All Implemented Interfaces:
Comparator<N>
Comparator class used in sorting the LopDAG in topological order. Refer to
doTopologicalSort_strict_order() in dml/lops/compile/Dag.java
Topological sort guarantees the following:
1) All lops with level i appear before any lop with level greater than i
(source nodes are at level 0)
2) Within a given level, nodes are ordered by their ID i.e., by the other in
which they are created
compare() method is designed to respect the above two requirements.
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
LopComparator
public LopComparator()
-
-
Method Details
-
compare
- Specified by:
comparein interfaceComparator<N extends Lop>
-