code: def _ordered(u, v):
      """Returns the nodes in an undirected edge in lower-triangular order"""
      return (u, v) if u < v else (v, u)
  
imports: import itertools
  import math
  from collections import defaultdict, namedtuple
  import networkx
  from networkx.utils import not_implemented_for, py_random_state
label_desc: Use image node_id 7 for calling a global function with example usage: _ordered(u, v) and returns: unknown