dimod icon indicating copy to clipboard operation
dimod copied to clipboard

Add keyword argument(s) to `QM.energies` and `BQM.energies` to force stricter input checking

Open arcondello opened this issue 4 years ago • 1 comments

A user may wish to test whether the given sample(s):

  1. Have exactly matching variables
  2. Have the correct values for the given variable vartype(s)

Something like

bqm.energies(samples, check_vartypes=True, check_variables=True)

or more simply

bqm.energies(samples, strict=True)

Additional Context Originally discussed as part of https://github.com/dwavesystems/dimod/issues/949 (1) is covered by https://github.com/dwavesystems/dimod/issues/244

arcondello avatar Aug 16 '21 16:08 arcondello

~Closed by #1010~ oops, wrong issue

arcondello avatar Sep 23 '21 16:09 arcondello