Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
bqpd committed Aug 16, 2021
1 parent 8eac752 commit f9f588a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion gpkit/constraints/prog_factories.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ def solvefn(self, solver=None, *, verbosity=1, skipsweepfailures=False,
return solvefn


# pylint: disable=too-many-locals,too-many-arguments,too-many-branches
# pylint: disable=too-many-locals,too-many-arguments,too-many-branches,too-many-statements
def run_sweep(genfunction, self, solution, skipsweepfailures,
constants, sweep, linked, solver, verbosity, **kwargs):
"Runs through a sweep."
Expand Down
6 changes: 3 additions & 3 deletions gpkit/solvers/cvxopt.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from gpkit.exceptions import UnknownInfeasible, DualInfeasible


# pylint: disable=too-many-locals
# pylint: disable=too-many-locals,too-many-statements
def optimize(*, c, A, k, meq_idxs, use_leqs=True, **kwargs):
"""Interface to the CVXOPT solver
Expand Down Expand Up @@ -47,11 +47,11 @@ def optimize(*, c, A, k, meq_idxs, use_leqs=True, **kwargs):
for i, n_monomials in enumerate(k):
start = sum(k[:i])
mons = range(start, start+k[i])
A_m = A[mons,:].tocoo()
A_m = A[mons, :].tocoo()
chash = hash((c[i], tuple(A_m.data), tuple(A_m.row), tuple(A_m.col)))
if chash in constraint_hashes:
continue # already got it
elif i: # skip cost posy
if i: # skip cost posy
constraint_hashes.add(chash)
if use_leqs and start in meq_idxs.all:
if start in meq_idxs.first_half:
Expand Down

0 comments on commit f9f588a

Please sign in to comment.