Skip to content

Commit

Permalink
fixing bug in gravity packing, adding F401 to ruff ignore list
Browse files Browse the repository at this point in the history
  • Loading branch information
jgostick committed Mar 12, 2024
1 parent 502b761 commit ebb2c3f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -164,3 +164,5 @@ exclude = [".git", ".github", ".venv", "build", "docs", "examples", "test"]
line-length = 92
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["E402", "F401", "F403"]
[tool.ruff.lint]
extend-ignore = ["F401"]
2 changes: 1 addition & 1 deletion src/porespy/generators/_pseudo_packings.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ def pseudo_gravity_packing(
# Generate elevation values to initialize queue
from porespy.generators import ramp
h = ramp(im.shape, inlet=0, outlet=im.shape[0], axis=0)*mask
h = h*1.0 + np.random.rand(len(h))
h = h*1.0 + np.random.rand(*im.shape)
tmp = np.arange(h.size)[mask.flatten()]
inds = np.vstack(np.unravel_index(tmp, im.shape)).T
h = h.flatten()[mask.flatten()]
Expand Down

0 comments on commit ebb2c3f

Please sign in to comment.