openjij.cxxjij.graph

Contents

openjij.cxxjij.graph#

cxxjij submodule for graph

class openjij.cxxjij.graph.BinaryPolynomialModel#

Bases: pybind11_object

__init__(self: openjij.cxxjij.graph.BinaryPolynomialModel, key_list: list[list[Union[int, str, list[Union[int, str]]]]], value_list: list[float]) -> None

__init__(self: BinaryPolynomialModel, key_list: list[list[int | str | list[int | str]]], value_list: list[float]) None#
__new__(**kwargs)#
calculate_energy(self: BinaryPolynomialModel, arg0: list[int]) float#
get_adjacency_list(self: BinaryPolynomialModel) list[list[int]]#
get_degree(self: BinaryPolynomialModel) int#
get_estimated_max_energy_difference(self: BinaryPolynomialModel) float#
get_estimated_min_energy_difference(self: BinaryPolynomialModel) float#
get_index_list(self: BinaryPolynomialModel) list[int | str | list[int | str]]#
get_index_map(self: BinaryPolynomialModel) dict[int | str | list[int | str], int]#
get_key_value_list(self: BinaryPolynomialModel) list[tuple[list[int], float]]#
get_system_size(self: BinaryPolynomialModel) int#
class openjij.cxxjij.graph.CSRSparse#

Bases: Graph

__init__(*args, **kwargs) Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.CSRSparse, interaction: scipy.sparse.csr_matrix[numpy.float64]) -> None

  2. __init__(self: openjij.cxxjij.graph.CSRSparse, other: openjij.cxxjij.graph.CSRSparse) -> None

__init__(*args, **kwargs)#

Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.CSRSparse, interaction: scipy.sparse.csr_matrix[numpy.float64]) -> None

  2. __init__(self: openjij.cxxjij.graph.CSRSparse, other: openjij.cxxjij.graph.CSRSparse) -> None

__new__(**kwargs)#
calc_energy(*args, **kwargs)#

Overloaded function.

  1. calc_energy(self: openjij.cxxjij.graph.CSRSparse, spins: numpy.ndarray[numpy.float64[m, 1]]) -> float

  2. calc_energy(self: openjij.cxxjij.graph.CSRSparse, spins: list[int]) -> float

gen_binary(*args, **kwargs)#

Overloaded function.

  1. gen_binary(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_binary(self: openjij.cxxjij.graph.Graph) -> list[int]

gen_spin(*args, **kwargs)#

Overloaded function.

  1. gen_spin(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_spin(self: openjij.cxxjij.graph.Graph) -> list[int]

get_interactions(self: CSRSparse) csr_matrix[numpy.float64]#
size(self: Graph) int#
class openjij.cxxjij.graph.Chimera#

Bases: Sparse

__init__(*args, **kwargs) Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Chimera, num_row: int, num_column: int, init_val: float = 0) -> None

  2. __init__(self: openjij.cxxjij.graph.Chimera, other: openjij.cxxjij.graph.Chimera) -> None

  3. __init__(self: openjij.cxxjij.graph.Chimera, obj: object, num_row: int, num_column: int, init_val: float = 0) -> None

__init__(*args, **kwargs)#

Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Chimera, num_row: int, num_column: int, init_val: float = 0) -> None

  2. __init__(self: openjij.cxxjij.graph.Chimera, other: openjij.cxxjij.graph.Chimera) -> None

  3. __init__(self: openjij.cxxjij.graph.Chimera, obj: object, num_row: int, num_column: int, init_val: float = 0) -> None

__new__(**kwargs)#
adj_nodes(self: Sparse, arg0: int) list[int]#
calc_energy(*args, **kwargs)#

Overloaded function.

  1. calc_energy(self: openjij.cxxjij.graph.Sparse, spins: numpy.ndarray[numpy.float64[m, 1]]) -> float

  2. calc_energy(self: openjij.cxxjij.graph.Sparse, spins: list[int]) -> float

gen_binary(*args, **kwargs)#

Overloaded function.

  1. gen_binary(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_binary(self: openjij.cxxjij.graph.Graph) -> list[int]

gen_spin(*args, **kwargs)#

Overloaded function.

  1. gen_spin(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_spin(self: openjij.cxxjij.graph.Graph) -> list[int]

get_num_column(self: Chimera) int#
get_num_edges(self: Sparse) int#
get_num_in_chimera(self: Chimera) int#
get_num_row(self: Chimera) int#
size(self: Graph) int#
to_ind(self: Chimera, arg0: int, arg1: int, arg2: int) int#
to_rci(self: Chimera, arg0: int) tuple[int, int, int]#
class openjij.cxxjij.graph.ChimeraDir#

Bases: pybind11_object

Members:

PLUS_R

MINUS_R

PLUS_C

MINUS_C

IN_0or4

IN_1or5

IN_2or6

IN_3or7

__init__(self: openjij.cxxjij.graph.ChimeraDir, value: int) -> None

__init__(self: ChimeraDir, value: int) None#
__new__(**kwargs)#
IN_0or4 = <ChimeraDir.IN_0or4: 4>#
IN_1or5 = <ChimeraDir.IN_1or5: 5>#
IN_2or6 = <ChimeraDir.IN_2or6: 6>#
IN_3or7 = <ChimeraDir.IN_3or7: 7>#
MINUS_C = <ChimeraDir.MINUS_C: 3>#
MINUS_R = <ChimeraDir.MINUS_R: 1>#
PLUS_C = <ChimeraDir.PLUS_C: 2>#
PLUS_R = <ChimeraDir.PLUS_R: 0>#
property name#
property value#
class openjij.cxxjij.graph.Dense#

Bases: Graph

__init__(*args, **kwargs) Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Dense, num_spins: int) -> None

  2. __init__(self: openjij.cxxjij.graph.Dense, obj: object) -> None

  3. __init__(self: openjij.cxxjij.graph.Dense, other: openjij.cxxjij.graph.Dense) -> None

__init__(*args, **kwargs)#

Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Dense, num_spins: int) -> None

  2. __init__(self: openjij.cxxjij.graph.Dense, obj: object) -> None

  3. __init__(self: openjij.cxxjij.graph.Dense, other: openjij.cxxjij.graph.Dense) -> None

__new__(**kwargs)#
calc_energy(*args, **kwargs)#

Overloaded function.

  1. calc_energy(self: openjij.cxxjij.graph.Dense, spins: numpy.ndarray[numpy.float64[m, 1]]) -> float

  2. calc_energy(self: openjij.cxxjij.graph.Dense, spins: list[int]) -> float

gen_binary(*args, **kwargs)#

Overloaded function.

  1. gen_binary(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_binary(self: openjij.cxxjij.graph.Graph) -> list[int]

gen_spin(*args, **kwargs)#

Overloaded function.

  1. gen_spin(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_spin(self: openjij.cxxjij.graph.Graph) -> list[int]

get_interactions(self: Dense) ndarray[numpy.float64[m, n]]#
set_interaction_matrix(self: Dense, interaction: ndarray[numpy.float64[m, n]]) None#
size(self: Graph) int#
class openjij.cxxjij.graph.Dir#

Bases: pybind11_object

Members:

PLUS_R

MINUS_R

PLUS_C

MINUS_C

__init__(self: openjij.cxxjij.graph.Dir, value: int) -> None

__init__(self: Dir, value: int) None#
__new__(**kwargs)#
MINUS_C = <Dir.MINUS_C: 3>#
MINUS_R = <Dir.MINUS_R: 1>#
PLUS_C = <Dir.PLUS_C: 2>#
PLUS_R = <Dir.PLUS_R: 0>#
property name#
property value#
class openjij.cxxjij.graph.Graph#

Bases: pybind11_object

__init__(self: openjij.cxxjij.graph.Graph, num_spins: int) -> None

__init__(self: Graph, num_spins: int) None#
__new__(**kwargs)#
gen_binary(*args, **kwargs)#

Overloaded function.

  1. gen_binary(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_binary(self: openjij.cxxjij.graph.Graph) -> list[int]

gen_spin(*args, **kwargs)#

Overloaded function.

  1. gen_spin(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_spin(self: openjij.cxxjij.graph.Graph) -> list[int]

size(self: Graph) int#
class openjij.cxxjij.graph.IsingPolynomialModel#

Bases: pybind11_object

__init__(self: openjij.cxxjij.graph.IsingPolynomialModel, key_list: list[list[Union[int, str, list[Union[int, str]]]]], value_list: list[float]) -> None

__init__(self: IsingPolynomialModel, key_list: list[list[int | str | list[int | str]]], value_list: list[float]) None#
__new__(**kwargs)#
calculate_energy(self: IsingPolynomialModel, arg0: list[int]) float#
get_adjacency_list(self: IsingPolynomialModel) list[list[int]]#
get_degree(self: IsingPolynomialModel) int#
get_estimated_max_energy_difference(self: IsingPolynomialModel) float#
get_estimated_min_energy_difference(self: IsingPolynomialModel) float#
get_index_list(self: IsingPolynomialModel) list[int | str | list[int | str]]#
get_index_map(self: IsingPolynomialModel) dict[int | str | list[int | str], int]#
get_key_value_list(self: IsingPolynomialModel) list[tuple[list[int], float]]#
get_system_size(self: IsingPolynomialModel) int#
class openjij.cxxjij.graph.Polynomial#

Bases: Graph

__init__(*args, **kwargs) Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Polynomial, num_variables: int) -> None

  2. __init__(self: openjij.cxxjij.graph.Polynomial, obj: object) -> None

__init__(*args, **kwargs)#

Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Polynomial, num_variables: int) -> None

  2. __init__(self: openjij.cxxjij.graph.Polynomial, obj: object) -> None

__new__(**kwargs)#
calc_energy(self: Polynomial, spins: list[int], omp_flag: bool = True) float#
energy(self: Polynomial, spins: list[int], omp_flag: bool = True) float#
gen_binary(*args, **kwargs)#

Overloaded function.

  1. gen_binary(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_binary(self: openjij.cxxjij.graph.Graph) -> list[int]

gen_spin(*args, **kwargs)#

Overloaded function.

  1. gen_spin(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_spin(self: openjij.cxxjij.graph.Graph) -> list[int]

get_num_interactions(self: Polynomial) int#
get_polynomial(self: Polynomial) dict#
size(self: Graph) int#
class openjij.cxxjij.graph.Sparse#

Bases: Graph

__init__(*args, **kwargs) Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Sparse, num_spins: int, num_edges: int) -> None

  2. __init__(self: openjij.cxxjij.graph.Sparse, num_spins: int) -> None

  3. __init__(self: openjij.cxxjij.graph.Sparse, obj: object, num_edges: int) -> None

  4. __init__(self: openjij.cxxjij.graph.Sparse, obj: object) -> None

  5. __init__(self: openjij.cxxjij.graph.Sparse, other: openjij.cxxjij.graph.Sparse) -> None

__init__(*args, **kwargs)#

Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Sparse, num_spins: int, num_edges: int) -> None

  2. __init__(self: openjij.cxxjij.graph.Sparse, num_spins: int) -> None

  3. __init__(self: openjij.cxxjij.graph.Sparse, obj: object, num_edges: int) -> None

  4. __init__(self: openjij.cxxjij.graph.Sparse, obj: object) -> None

  5. __init__(self: openjij.cxxjij.graph.Sparse, other: openjij.cxxjij.graph.Sparse) -> None

__new__(**kwargs)#
adj_nodes(self: Sparse, arg0: int) list[int]#
calc_energy(*args, **kwargs)#

Overloaded function.

  1. calc_energy(self: openjij.cxxjij.graph.Sparse, spins: numpy.ndarray[numpy.float64[m, 1]]) -> float

  2. calc_energy(self: openjij.cxxjij.graph.Sparse, spins: list[int]) -> float

gen_binary(*args, **kwargs)#

Overloaded function.

  1. gen_binary(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_binary(self: openjij.cxxjij.graph.Graph) -> list[int]

gen_spin(*args, **kwargs)#

Overloaded function.

  1. gen_spin(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_spin(self: openjij.cxxjij.graph.Graph) -> list[int]

get_num_edges(self: Sparse) int#
size(self: Graph) int#
class openjij.cxxjij.graph.Square#

Bases: Sparse

__init__(*args, **kwargs) Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Square, num_row: int, num_column: int, init_val: float = 0) -> None

  2. __init__(self: openjij.cxxjij.graph.Square, other: openjij.cxxjij.graph.Square) -> None

  3. __init__(self: openjij.cxxjij.graph.Square, obj: object, num_row: int, num_column: int, init_val: float = 0) -> None

__init__(*args, **kwargs)#

Overloaded function.

  1. __init__(self: openjij.cxxjij.graph.Square, num_row: int, num_column: int, init_val: float = 0) -> None

  2. __init__(self: openjij.cxxjij.graph.Square, other: openjij.cxxjij.graph.Square) -> None

  3. __init__(self: openjij.cxxjij.graph.Square, obj: object, num_row: int, num_column: int, init_val: float = 0) -> None

__new__(**kwargs)#
adj_nodes(self: Sparse, arg0: int) list[int]#
calc_energy(*args, **kwargs)#

Overloaded function.

  1. calc_energy(self: openjij.cxxjij.graph.Sparse, spins: numpy.ndarray[numpy.float64[m, 1]]) -> float

  2. calc_energy(self: openjij.cxxjij.graph.Sparse, spins: list[int]) -> float

gen_binary(*args, **kwargs)#

Overloaded function.

  1. gen_binary(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_binary(self: openjij.cxxjij.graph.Graph) -> list[int]

gen_spin(*args, **kwargs)#

Overloaded function.

  1. gen_spin(self: openjij.cxxjij.graph.Graph, seed: int) -> list[int]

  2. gen_spin(self: openjij.cxxjij.graph.Graph) -> list[int]

get_num_column(self: Square) int#
get_num_edges(self: Sparse) int#
get_num_row(self: Square) int#
size(self: Graph) int#
to_ind(self: Square, arg0: int, arg1: int) int#
to_rc(self: Square, arg0: int) tuple[int, int]#