dimod
dimod copied to clipboard
SampleSet.recalculate_energy method or similar
sampleset.recalculate_energy(bqm)
should change the sampleset's energy to that as calculated with the given bqm.
For posterity, this can (as of 0.9.11) be done simply with
sampleset.record.energy = bqm.energies(sampleset)
It still might be worth implementing a method, but the one-liner isn't too bad.