pytorch/benchmarks/sparse
Xuehai Pan 84a01dd825 [BE][CI] bump ruff to 0.9.2: multiline assert statements
Reference: https://docs.astral.sh/ruff/formatter/black/#assert-statements

> Unlike Black, Ruff prefers breaking the message over breaking the assertion, similar to how both Ruff and Black prefer breaking the assignment value over breaking the assignment target:
>
> ```python
> # Input
> assert (
>     len(policy_types) >= priority + num_duplicates
> ), f"This tests needs at least {priority+num_duplicates} many types."
>
>
> # Black
> assert (
>     len(policy_types) >= priority + num_duplicates
> ), f"This tests needs at least {priority+num_duplicates} many types."
>
> # Ruff
> assert len(policy_types) >= priority + num_duplicates, (
>     f"This tests needs at least {priority + num_duplicates} many types."
> )
> ```

ghstack-source-id: f4c1376e01
Pull Request resolved: https://github.com/pytorch/pytorch/pull/144546
2025-02-10 22:00:05 +08:00
..
dlmc Fix unused Python variables outside torch/ and test/ (#136359) 2024-12-11 17:10:23 +00:00
__init__.py
README.md
spmm.py
spmv.py
test_csr.sh
triton_ops.py [BE][CI] bump ruff to 0.9.2: multiline assert statements 2025-02-10 22:00:05 +08:00
utils.py

#Sparse benchmarks

These sets of benchmarks are for the sparse matrix functionality. They exist for comparing the performance of sparse matrix routines such as SpMV between various sparse matrix formats and with other frameworks such as TensorFlow.