Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trivial problem returns NaN #47

Open
bemilio opened this issue Jun 28, 2022 · 0 comments
Open

Trivial problem returns NaN #47

bemilio opened this issue Jun 28, 2022 · 0 comments

Comments

@bemilio
Copy link

bemilio commented Jun 28, 2022

Running the following trivial QP problem returns NaN:

import torch
from qpth.qp import QPFunction

Q = torch.tensor([[[1.]]]) 
q = torch.tensor([[1.]])
A_eq = torch.tensor([[[0.]]])
A_ineq = torch.tensor([[[0.]]])
b_ineq = torch.tensor([[0.]])
b_eq = torch.tensor([[0.]])
QPFunction(verbose=True)(Q, q, A_ineq, b_ineq, A_eq, b_eq)

Output:

iter: 1, pri_resid: nan, dual_resid: nan, mu: nan
iter: 2, pri_resid: nan, dual_resid: nan, mu: nan
iter: 3, pri_resid: nan, dual_resid: nan, mu: nan
tensor([[nan]])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant