summaryrefslogtreecommitdiff
path: root/science/py-dwave-neal/files/example.py
blob: be734d9f7229aa739f4cd3f9f9217ebb88d84c8c (plain) (blame)
1
2
3
4
5
6
7
8
9
import neal

sampler = neal.SimulatedAnnealingSampler()

h = {0: -1, 1: -1}
J = {(0, 1): -1}
sampleset = sampler.sample_ising(h, J)

print(sampleset)