Remove deprecated logic from algorithms#18
Conversation
Pull Request Test Coverage Report for Build 5659622531
💛 - Coveralls |
| with self.assertWarns(DeprecationWarning): | ||
| result = spsa.optimize(circuit.num_parameters, objective, initial_point=initial_point) | ||
| result = spsa.minimize(objective, x0=initial_point) |
There was a problem hiding this comment.
I would have thought the assertWarns line should have gone, as it was to check that the optimize method indeed raised a DeprecationWarning as was intended. I am not sure how this is passing now - nothing in the minimize path should be deprecated I would have thought!
There was a problem hiding this comment.
A deprecation warning is raised from the evolved operator ansatz, I believe, because it still uses opflow in some methods. This also happens in some of the tests from #17, where the assertion is still needed.
There was a problem hiding this comment.
Ok, this more that we should be changing the code to avoid that deprecation if possible. Its not really something that we are raising in our code and we want to make sure it is and gets seen by the end-user. For this case that assertWarns should not be there - I can remove it (outdenting the call to minimize of course) and it passes fine.
There was a problem hiding this comment.
Since its passing CI lets go with this - it is likely that once the opflow/QI logic use here is all removed that this will need to be revisited.
Co-authored-by: Steve Wood <40241007+woodsp-ibm@users.noreply.github.com>
Co-authored-by: Steve Wood <40241007+woodsp-ibm@users.noreply.github.com>
Summary
Fixes #12
Details and comments
Missing reno.