This repository has been archived by the owner on Dec 7, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 376
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
QSVM L2 Reg. introduction for convergence and over-fitting issue (#1378)
* First update on qp_solver with L2 * Update test for lambda2 * Add reno Co-authored-by: woodsp <[email protected]> Co-authored-by: Steve Wood <[email protected]>
- Loading branch information
1 parent
8957a61
commit 739e330
Showing
5 changed files
with
22 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
fixes: | ||
- | | ||
optimize_svm method of qp_solver would sometimes fail resulting in an error like this | ||
`ValueError: cannot reshape array of size 1 into shape (200,1)` This addresses the issue | ||
by adding an L2 norm parameter, lambda2, which defaults to 0.001 but can be changed via | ||
the QSVM algorithm, as needed, to facilitate convergence. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters