Skip to content

Commit

Permalink
[pre-commit.ci] pre-commit autoupdate (#217)
Browse files Browse the repository at this point in the history
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/psf/black: 23.12.1 → 24.3.0](psf/black@23.12.1...24.3.0)
- [github.com/PyCQA/flake8: 6.1.0 → 7.0.0](PyCQA/flake8@6.1.0...7.0.0)
- [github.com/pre-commit/mirrors-mypy: v1.8.0 → v1.9.0](pre-commit/mirrors-mypy@v1.8.0...v1.9.0)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
pre-commit-ci[bot] authored May 28, 2024
1 parent 8359961 commit 9e905fb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ repos:
- id: check-yaml

- repo: https://github.com/psf/black
rev: 23.12.1
rev: 24.3.0
hooks:
- id: black-jupyter

- repo: https://github.com/PyCQA/flake8
rev: 6.1.0
rev: 7.0.0
hooks:
- id: flake8
- repo: https://github.com/asottile/seed-isort-config
Expand All @@ -37,7 +37,7 @@ repos:
- id: prettier

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.8.0
rev: v1.9.0
hooks:
- id: mypy
additional_dependencies: [
Expand Down
8 changes: 5 additions & 3 deletions xbatcher/testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,11 @@ def _get_sample_length(
"""
if generator.concat_input_dims:
batch_concat_dims = [
generator.batch_dims.get(dim) // length
if generator.batch_dims.get(dim)
else generator.ds.sizes.get(dim) // length
(
generator.batch_dims.get(dim) // length
if generator.batch_dims.get(dim)
else generator.ds.sizes.get(dim) // length
)
for dim, length in generator.input_dims.items()
]
else:
Expand Down

0 comments on commit 9e905fb

Please sign in to comment.