Skip to content

Commit 7d82b0b

Browse files
author
Luke Shaw
committed
Update comments
1 parent 6260e42 commit 7d82b0b

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

src/blosc2/lazyexpr.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2789,7 +2789,9 @@ def _new_expr(cls, expression, operands, guess, out=None, where=None, ne_args=No
27892789
# if new_expr has where_args, must have come from where(...) - or possibly where(where(..
27902790
# since 5*where, where + ... are evaluated eagerly
27912791
if hasattr(new_expr, "_where_args"):
2792-
st = expression_.find("where(") + 6 # could probably just be set = 6
2792+
st = (
2793+
expression_.find("where(") + 6
2794+
) # expr always begins where( - could just set = 6 probably
27932795
finalexpr = ""
27942796
counter = 0
27952797
for char in expression_[st:]: # get rid of external where(...)

tests/ndarray/test_lazyexpr_fields.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -258,12 +258,12 @@ def test_lazy_where(array_fixture):
258258
nres = ne_evaluate("where(where(na2 < 0, 3, na2) > 3, 10, na1)")
259259
np.testing.assert_allclose(res[:], nres)
260260

261-
# Test 4: muliplied wheres
261+
# Test 4: multiplied wheres
262262
# Test with string expression
263-
expr = blosc2.lazyexpr("1*where(a2 < 0, 3, a2)")
263+
expr = blosc2.lazyexpr("1 * where(a2 < 0, 3, a2)")
264264
# Test with eval
265265
res = expr.compute()
266-
nres = ne_evaluate("1*where(na2 < 0, 3, na2)")
266+
nres = ne_evaluate("1 * where(na2 < 0, 3, na2)")
267267
np.testing.assert_allclose(res[:], nres)
268268

269269

0 commit comments

Comments
 (0)