dwave.graphs.algorithms.automorphism.SchreierContext#

class SchreierContext(graph: Graph, graph_coloring: Mapping[Hashable, int] | None = None, node_order: list[Hashable] | None = None)[source]#

This object holds mutable states used throughout the automorphism calculation.

Parameters:
  • graph – A NetworkX Graph object representing the input graph.

  • graph_coloring – Optional mapping from original vertex label to color label. When provided, the initial partition separates vertices by color.

  • node_order – Optional ordering of the original node labels. Must be contiguous and contain all nodes in the graph. Used to give disjoint components contiguous indices.

__init__(graph: Graph, graph_coloring: Mapping[Hashable, int] | None = None, node_order: list[Hashable] | None = None) None[source]#

Methods

__init__(graph[, graph_coloring, node_order])

Attributes

edge_orbits

Edge orbits induced by the coset representatives in u_vector and returned in the basis of relabelled nodes (0...n-1).

edge_orbits_original_labels

Edge orbits induced by the coset representatives in u_vector and returned with the original node labels.

index_to_node

The mapping from the basis of relabelled nodes (0...n-1) to the original node labels.

leaf_nodes

Number of leaf nodes encountered in the search tree.

node_to_index

The mapping from the original node labels to the basis of relabelled nodes (0...n-1).

nodes_reached

Total number of nodes reached during traversal of the search tree.

num_automorphisms

Number of automorphisms implied by u_vector.

u_map

Map from coset representative group index to stabilizer index.

u_vector

Coset representatives grouped by stabilizer index.

vertex_orbits

Vertex orbits induced by the coset representatives in u_vector and returned in the basis of relabelled nodes (0...n-1).

vertex_orbits_original_labels

Vertex orbits induced by the coset representatives in u_vector and returned with the original node labels.