Skip to content
This repository has been archived by the owner on Dec 7, 2021. It is now read-only.

[Stable] Release 0.6.5 - Remove cvxopt from install, backport fix for issue #768 #858

Merged
merged 4 commits into from
Mar 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,22 @@ Changelog](http://keepachangelog.com/en/1.0.0/).
> - **Fixed**: for any bug fixes.
> - **Security**: in case of vulnerabilities.

[UNRELEASED](https://github.com/Qiskit/qiskit-aqua/compare/0.6.4...HEAD)
[UNRELEASED](https://github.com/Qiskit/qiskit-aqua/compare/0.6.5...HEAD)
========================================================================

[0.6.5](https://github.com/Qiskit/qiskit-aqua/compare/0.6.4...0.6.5) - 2020-03-16
=================================================================================

Removed
-------

- Removed cvxopt from installation. (#858)

Fixed
-----

- Fixes issue #768. The AQGD optimizer if condition in func converged was ignored. That kept breaking the while loop for training. (#858)

[0.6.4](https://github.com/Qiskit/qiskit-aqua/compare/0.6.3...0.6.4) - 2020-02-06
=================================================================================

Expand Down
2 changes: 1 addition & 1 deletion qiskit/aqua/VERSION.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.6.4
0.6.5
2 changes: 1 addition & 1 deletion qiskit/aqua/components/optimizers/aqgd.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ def converged(self, objval, n=2):
Returns:
bool: Whether or not the optimization has converged.
"""
if not hasattr(self, '_previous_loss'):
if self._previous_loss is None:
self._previous_loss = [objval + 2 * self._tol] * n

if all([absolute(objval - prev) < self._tol for prev in self._previous_loss]):
Expand Down
1 change: 0 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ numpy>=1.13
psutil>=5
jsonschema>=2.6
scikit-learn>=0.20.0
cvxopt; python_version < '3.8' or sys_platform != 'win32'
dlx
docplex
fastdtw
Expand Down
1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"psutil>=5",
"jsonschema>=2.6",
"scikit-learn>=0.20.0",
"cvxopt; python_version < '3.8' or sys_platform != 'win32'",
"dlx",
"docplex",
"fastdtw",
Expand Down
15 changes: 9 additions & 6 deletions test/aqua/test_qsvm.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,15 @@ def test_qsvm_binary_via_run_algorithm(self):
'name': 'QSVM'
}
}
backend = BasicAer.get_backend('qasm_simulator')
algo_input = ClassificationInput(training_input, test_input, total_array)
result = run_algorithm(params, algo_input, backend=backend)
self.assertEqual(result['testing_accuracy'], 0.6)
self.assertEqual(result['predicted_classes'], ['A', 'A', 'A', 'A', 'A',
'A', 'B', 'A', 'A', 'A'])
try:
backend = BasicAer.get_backend('qasm_simulator')
algo_input = ClassificationInput(training_input, test_input, total_array)
result = run_algorithm(params, algo_input, backend=backend)
self.assertEqual(result['testing_accuracy'], 0.6)
self.assertEqual(result['predicted_classes'], ['A', 'A', 'A', 'A', 'A',
'A', 'B', 'A', 'A', 'A'])
except NameError as ex:
self.skipTest(str(ex))

def test_qsvm_binary_directly(self):
""" QSVM Binary Directly test """
Expand Down