iqm.benchmarks.utils.remove_directed_duplicates_to_list

iqm.benchmarks.utils.remove_directed_duplicates_to_list#

iqm.benchmarks.utils.remove_directed_duplicates_to_list(cp_map: CouplingMap) List[List[int]]#

Remove duplicate edges from a coupling map and returns as a list of edges (as a list of pairs of vertices).

Parameters:

cp_map (CouplingMap) – A list of pairs of integers, representing a coupling map.

Returns:

the edges of the coupling map.

Return type:

List[List[int]]