in batch.py:100 ry is set to 0.0 if there are no equality constraints:
ry = torch.bmm(x.unsqueeze(1), A.transpose(
1, 2)).squeeze(1) - b if neq > 0 else 0.0
However when using the IR_UNOPT solver, kkt_resid_reg will fail with IndexError: Dimension out of range (expected to be in range of [-1, 0], but got 2) since the below unsqueeze operation is attempted on the float:
dx, ds, dz, dy, rx, rs, rz, ry = [
x.unsqueeze(2) if x is not None else None for x in
[dx, ds, dz, dy, rx, rs, rz, ry] ]
I lack the understanding of this library to know what the exact fix is, but I thought I'd report it.
in batch.py:100
ryis set to 0.0 if there are no equality constraints:However when using the
IR_UNOPTsolver,kkt_resid_regwill fail withIndexError: Dimension out of range (expected to be in range of [-1, 0], but got 2)since the belowunsqueezeoperation is attempted on the float:I lack the understanding of this library to know what the exact fix is, but I thought I'd report it.