Result

class Result

Container of optimization solutions and conversion/runtime metadata.

Methods

__init__

sort

Sort solutions by feasibility and objective value.

Attributes

best

Best solution in the result set.

client_result

Solver/client result.

embedding

Graph embedding information.

execution_time

The time the solver used to solve the problem.

filter_solution

Whether to filter out infeasible solutions.

intermediate

Model conversion information.

num_solves

Number of solve executions aggregated.

response_time

The time between sending the request and receiving the response from the solver.

solutions

View of all solutions.

split

Split view for each independent solve.

total_time

Total time including conversion and solve.

class GraphConversion

Graph embedding conversion details used during solving.

class ChainBreakFractions

List-like view of chain break fractions.

class Iterator
__init__(*args, **kwargs)
__iter__(self) Iterator

__iter__

戻り値の型:

Iterator

__next__(self) float

__next__

戻り値の型:

float

__bool__(self) bool

__bool__

戻り値の型:

bool

__getitem__(self, key: int) float

__getitem__

パラメータ:

key (int)

戻り値の型:

float

__init__(*args, **kwargs)
__iter__(self) Iterator

__iter__

戻り値の型:

Iterator

__len__(self) int

__len__

戻り値の型:

int

__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

__init__(*args, **kwargs)
__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

property chain_break_fractions

Chain break fraction for each solve.

戻り値の型:

ChainBreakFractions

property chains

Embedding chains for each logical variable.

戻り値の型:

list[ndarray[dtype=uint32, writable=False]]

property dst_graph

Destination (physical) graph used for embedding.

戻り値の型:

Graph

property num_variables

Number of physical variables used after embedding.

戻り値の型:

int

property poly

Embedded polynomial.

戻り値の型:

Poly

property src_graph

Source (input polynomial) graph for embedding.

戻り値の型:

list[tuple[int, int]]

property values_list

Physical variable assignments for each solve.

戻り値の型:

ValuesList

class ModelConversion

Model conversion details used during solving.

class IntermediateMapping

Mapping between original and intermediate variables during model conversion.

class ItemsView

View of key-value pairs in IntermediateMapping.

__bool__(self) bool

__bool__

戻り値の型:

bool

__init__(*args, **kwargs)
__iter__(self) ItemsView

__iter__

戻り値の型:

ItemsView

__len__(self) int

__len__

戻り値の型:

int

__next__(self) tuple[Poly, Poly]

__next__

戻り値の型:

tuple[Poly, Poly]

class KeysView

View of keys in IntermediateMapping.

__bool__(self) bool

__bool__

戻り値の型:

bool

__contains__(self, arg: Poly, /) bool
__contains__(self, arg: object, /) bool

__contains__

Overload 1.

Args:
  • arg (amplify.Poly)

Returns:

bool:

Overload 2.

Args:
  • arg (object)

Returns:

bool:

__init__(*args, **kwargs)
__iter__(self) KeysView

__iter__

戻り値の型:

KeysView

__len__(self) int

__len__

戻り値の型:

int

__next__(self) Poly

__next__

戻り値の型:

Poly

class ValuesView

View of values in IntermediateMapping.

__bool__(self) bool

__bool__

戻り値の型:

bool

__init__(*args, **kwargs)
__iter__(self) ValuesView

__iter__

戻り値の型:

ValuesView

__len__(self) int

__len__

戻り値の型:

int

__next__(self) Poly

__next__

戻り値の型:

Poly

__bool__(self) bool

__bool__

戻り値の型:

bool

__contains__(self, arg: Poly, /) bool
__contains__(self, arg: object, /) bool

__contains__

Overload 1.

Args:
  • arg (amplify.Poly)

Returns:

bool:

Overload 2.

Args:
  • arg (object)

Returns:

bool:

__getitem__(self, arg: Poly, /) Poly

__getitem__

パラメータ:

arg (Poly)

戻り値の型:

Poly

__init__(*args, **kwargs)
__iter__(self) KeysView

__iter__

戻り値の型:

KeysView

__len__(self) int

__len__

戻り値の型:

int

__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

items(self) ItemsView

items

戻り値の型:

ItemsView

keys(self) KeysView

keys

戻り値の型:

KeysView

values(self) ValuesView

values

戻り値の型:

ValuesView

__init__(*args, **kwargs)
__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

property mapping

Mapping from input variables to intermediate expressions.

戻り値の型:

IntermediateMapping

property model

Intermediate model.

戻り値の型:

Model

property num_variables

Number of variables in the intermediate model.

戻り値の型:

int

property values_list

Intermediate variable assignments for each solve.

戻り値の型:

ValuesList

class Solution

Single solution entry in Result.

__init__(*args, **kwargs)
__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

property feasible

Whether all constraints are satisfied.

戻り値の型:

bool

property objective

Objective function value.

戻り値の型:

float

property time

Time at which the solver found this solution.

戻り値の型:

timedelta

property values

Variable assignments of the solution.

戻り値の型:

Values

class SolutionList

List-like view of solutions.

class Iterator
__init__(*args, **kwargs)
__iter__(self) Iterator

__iter__

戻り値の型:

Iterator

__next__(self) Solution

__next__

戻り値の型:

Solution

__bool__(self) bool

__bool__

戻り値の型:

bool

__getitem__(self, key: int) Solution

__getitem__

パラメータ:

key (int)

戻り値の型:

Solution

__init__(*args, **kwargs)
__iter__(self) Iterator

__iter__

戻り値の型:

Iterator

__len__(self) int

__len__

戻り値の型:

int

__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

class SplitView

List-of-list-like view of solutions that splits solutions by independent solves.

__bool__(self) bool

__bool__

戻り値の型:

bool

__getitem__(self, key: int) Result

__getitem__

パラメータ:

key (int)

戻り値の型:

Result

__init__(*args, **kwargs)
__iter__(self) SplitView

__iter__

戻り値の型:

SplitView

__len__(self) int

__len__

戻り値の型:

int

__next__(self) Result

__next__

戻り値の型:

Result

class ValuesList

List-like view of value mappings for solutions.

class Iterator
__init__(*args, **kwargs)
__iter__(self) Iterator

__iter__

戻り値の型:

Iterator

__next__(self) Values

__next__

戻り値の型:

Values

__bool__(self) bool

__bool__

戻り値の型:

bool

__getitem__(self, key: int) Values

__getitem__

パラメータ:

key (int)

戻り値の型:

Values

__init__(*args, **kwargs)
__iter__(self) Iterator

__iter__

戻り値の型:

Iterator

__len__(self) int

__len__

戻り値の型:

int

__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

__class_getitem__()
__getitem__(self, key: int) Solution

__getitem__

パラメータ:

key (int)

戻り値の型:

Solution

__init__(*args, **kwargs)
__iter__(self) Iterator

__iter__

戻り値の型:

Iterator

__len__(self) int

__len__

戻り値の型:

int

__repr__(self) str

__repr__

戻り値の型:

str

__str__(self) str

__str__

戻り値の型:

str

sort(self) None

Sort solutions by feasibility and objective value.

__nb_signature__ = 'class Result[_BaseClient]'
property best

Best solution in the result set.

戻り値の型:

Solution

property client_result

Solver/client result.

戻り値の型:

Result | Result | SampleSet | SampleSet | SampleSet | Result | Result | Result | Result | amplify.DASClient.Result | Result | object | None

property embedding

Graph embedding information.

戻り値の型:

GraphConversion | None

property execution_time

The time the solver used to solve the problem.

戻り値の型:

timedelta

property filter_solution

Whether to filter out infeasible solutions.

戻り値の型:

bool

property intermediate

Model conversion information.

戻り値の型:

ModelConversion

property num_solves

Number of solve executions aggregated.

戻り値の型:

int

property response_time

The time between sending the request and receiving the response from the solver.

戻り値の型:

timedelta

property solutions

View of all solutions.

戻り値の型:

SolutionList

property split

Split view for each independent solve.

戻り値の型:

SplitView

property total_time

Total time including conversion and solve.

戻り値の型:

timedelta