Skip to content

Commit b362432

Browse files
authored
Merge pull request #53 from decarsg/feature/lmi-strictness
LMI Strictness
2 parents e6c7764 + 2e93cce commit b362432

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

CITATION.cff

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ authors:
1010
orcid: "https://orcid.org/0000-0002-1987-9268"
1111
affiliation: "McGill University"
1212
title: "decarsg/pykoop"
13-
version: v1.0.3
13+
version: v1.0.4
1414
doi: 10.5281/zenodo.5576490
1515
date-released: 2021-10-19
1616
url: "https://github.com/decarsg/pykoop"

pykoop/lmi_regressors.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -337,49 +337,49 @@ def _create_base_problem(
337337
problem.add_constraint(picos.block([
338338
[Z, U],
339339
[U.T, H_inv],
340-
]) >> 0)
340+
]) >> picos_eps)
341341
elif inv_method == 'pinv':
342342
H_inv = picos.Constant('H^+', _calc_Hpinv(H))
343343
problem.add_constraint(picos.block([
344344
[Z, U],
345345
[U.T, H_inv],
346-
]) >> 0)
346+
]) >> picos_eps)
347347
elif inv_method == 'eig':
348348
VsqrtLmb = picos.Constant('(V Lambda^(1/2))', _calc_VsqrtLmb(H))
349349
problem.add_constraint(
350350
picos.block([
351351
[Z, U * VsqrtLmb],
352352
[VsqrtLmb.T * U.T, 'I'],
353-
]) >> 0)
353+
]) >> picos_eps)
354354
elif inv_method == 'ldl':
355355
LsqrtD = picos.Constant('(L D^(1/2))', _calc_LsqrtD(H))
356356
problem.add_constraint(
357357
picos.block([
358358
[Z, U * LsqrtD],
359359
[LsqrtD.T * U.T, 'I'],
360-
]) >> 0)
360+
]) >> picos_eps)
361361
elif inv_method == 'chol':
362362
L = picos.Constant('L', _calc_L(H))
363363
problem.add_constraint(
364364
picos.block([
365365
[Z, U * L],
366366
[L.T * U.T, 'I'],
367-
]) >> 0)
367+
]) >> picos_eps)
368368
elif inv_method == 'sqrt':
369369
sqrtH = picos.Constant('sqrt(H)', _calc_sqrtH(H))
370370
problem.add_constraint(
371371
picos.block([
372372
[Z, U * sqrtH],
373373
[sqrtH.T * U.T, 'I'],
374-
]) >> 0)
374+
]) >> picos_eps)
375375
elif inv_method == 'svd':
376376
QSig = picos.Constant(
377377
'Q Sigma', _calc_QSig(X_unshifted, alpha_tikhonov, tsvd))
378378
problem.add_constraint(
379379
picos.block([
380380
[Z, U * QSig],
381381
[QSig.T * U.T, 'I'],
382-
]) >> 0)
382+
]) >> picos_eps)
383383
else:
384384
# Should never, ever get here.
385385
assert False
@@ -2473,7 +2473,7 @@ def _add_twonorm(problem: picos.Problem, U: picos.RealVariable,
24732473
gamma = picos.RealVariable('gamma', 1)
24742474
problem.add_constraint(
24752475
picos.block([[picos.diag(gamma, p), U.T],
2476-
[U, picos.diag(gamma, p_theta)]]) >> 0)
2476+
[U, picos.diag(gamma, p_theta)]]) >> picos_eps)
24772477
# Add term to cost function
24782478
alpha_scaled = picos.Constant('alpha_scaled_2', alpha_other)
24792479
if square_norm:

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
setuptools.setup(
77
name='pykoop',
8-
version='1.0.3',
8+
version='1.0.4',
99
description='Koopman operator identification library in Python',
1010
long_description=readme,
1111
author='Steven Dahdah',

0 commit comments

Comments
 (0)