dwave.system.composites.PolyCutOffComposite.sample_poly#

PolyCutOffComposite.sample_poly(poly, **kwargs)[source]#

Cutoff and sample from the provided binary polynomial.

Prunes the binary polynomial submitted to the child sampler by retaining only interactions with values commensurate with the sampler’s precision as specified by the cutoff argument. Also removes variables isolated post- or pre-removal of these interactions from the polynomial passed on to the child sampler, setting these variables to values that minimize the original polynomial’s energy for the returned samples.

Parameters:
  • poly (dimod.BinaryPolynomial) – Binary polynomial to be sampled from.

  • **parameters – Parameters for the sampling method, specified by the child sampler.

Returns:

SampleSet

Examples

See the example in PolyCutOffComposite.