Skip to content

Commit

Permalink
minor change
Browse files Browse the repository at this point in the history
  • Loading branch information
luk036 committed Oct 21, 2023
1 parent 8a07198 commit b766b8b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/ellalgo/oracles/profit_oracle.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,8 +265,7 @@ def assess_optim_q(
"""
if not retry:
# try continous y first
cut = self.omega.assess_feas(y, gamma);
if cut is not None:
if cut := self.omega.assess_feas(y, gamma):
return cut, y, None, True

xd = np.round(np.exp(y))
Expand All @@ -278,4 +277,4 @@ def assess_optim_q(

(grad, beta), gamma_new = self.omega.assess_optim(self.yd, gamma)
beta += grad.dot(self.yd - y) # reference as y
return (grad, beta), self.yd, gamma_new, False
return (grad, beta), self.yd, gamma_new, False

0 comments on commit b766b8b

Please sign in to comment.