compute_chebyshev center sometimes returns invalid points
Probably also an issue with making sure that problems and points live on the same space. For example if we give a starting point and a rounded problem to hopsy.sample, should the starting point already live in the rounded space (happens when computed on the rounded problem) OR should the starting point live in the original, unrounded space?
Also we should document from what space the starting point should come when creating markov chains.
This issue is open for discussion, here is an example:
# Problem: After rounding, chebychev center is not within bound constraints
# (Regardeless of `simplify=True/False`)
A = np.array([]).reshape(0,3)
b = np.array([])
lb = [0.01, 1e-10, 1e-10]
ub = [3, 0.1, 1e-06]
problem = hopsy.Problem(
A,
b,
model=None,
)
problem = hopsy.add_box_constraints(
problem,
lb,
ub,
simplify=False
)
chebyshev = hopsy.compute_chebyshev_center(problem)[:, 0]
print(chebyshev)
problem_rounded = hopsy.round(problem)
chebyshev_rounded = hopsy.compute_chebyshev_center(problem_rounded)[:, 0]
print(chebyshev_rounded)
Edited by Jadebeck, Johann Fredrik