Skip to content

Commit 9568735

Browse files
authored
Update CI tools & fix typos (#1386)
* Update pre-commit tools * Fix typos
1 parent c8f2769 commit 9568735

File tree

5 files changed

+11
-10
lines changed

5 files changed

+11
-10
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
repos:
22
- repo: https://github.com/astral-sh/ruff-pre-commit
3-
rev: v0.3.2
3+
rev: v0.6.9
44
hooks:
55
- id: ruff
66
args:
77
- --fix
88
- id: ruff-format
99
- repo: https://github.com/pre-commit/pre-commit-hooks
10-
rev: v4.5.0
10+
rev: v5.0.0
1111
hooks:
1212
- id: check-merge-conflict
1313
- id: check-yaml
@@ -18,6 +18,6 @@ repos:
1818
args:
1919
- --fix=lf
2020
- repo: https://github.com/crate-ci/typos
21-
rev: v1.18.2
21+
rev: v1.26.0
2222
hooks:
2323
- id: typos

_typos.toml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@
44
extend-ignore-re = [
55
"@Ther-nul", # valid Github user
66
]
7-
8-
[default.extend-identifiers]
7+
extend-ignore-identifiers-re = [
8+
".*arange.*",
9+
".*ARANGE.*",
10+
]
911

1012
[type.py.extend-words]
1113
"BA" = "BA" # used as a commented-out variable in tests

bitsandbytes/functional.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1864,7 +1864,7 @@ def percentile_clipping(grad: Tensor, gnorm_vec: Tensor, step: int, percentile:
18641864
gnorm_vec: torch.Tensor
18651865
Vector of gradient norms. 100 elements expected.
18661866
step: int
1867-
The current optimiation steps (number of past gradient norms).
1867+
The current optimization steps (number of past gradient norms).
18681868
18691869
"""
18701870
prev_device = pre_call(grad.device)

csrc/kernels.cu

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2661,7 +2661,7 @@ template <int THREADS, int ITEMS_PER_THREAD, int TILE_ROWS, int TILE_COLS, int T
26612661
//const int global_col = base_row; // block offset for col
26622662
if((base_col + subrow_loop_row + jrow + warp_id < outRows) && (base_row+warp_lane < rows))
26632663
{
2664-
// each row hae 32 columns and is offset by 1 to prevent bank conflict during storage into smem
2664+
// each row has 32 columns and is offset by 1 to prevent bank conflict during storage into smem
26652665
char data = smem_data[(subrow_loop_row + jrow + warp_id)*33 + warp_lane];
26662666

26672667
// each 32 columns we have new tile
@@ -2700,7 +2700,7 @@ template <int THREADS, int ITEMS_PER_THREAD, int TILE_ROWS, int TILE_COLS, int T
27002700
//const int global_col = base_row; // block offset for col
27012701
if((base_col + subrow_loop_row + jrow + warp_id < outRows) && (base_row+warp_lane < rows))
27022702
{
2703-
// each row hae 32 columns and is offset by 1 to prevent bank conflict during storage into smem
2703+
// each row has 32 columns and is offset by 1 to prevent bank conflict during storage into smem
27042704
char data = smem_data[(subrow_loop_row + jrow + warp_id)*33 + warp_lane];
27052705

27062706
// each 32 columns we have new tile
@@ -2777,7 +2777,7 @@ template <int THREADS, int ITEMS_PER_THREAD, int TILE_ROWS, int TILE_COLS, int T
27772777
//const int global_col = base_row; // block offset for col
27782778
if((base_col + subrow_loop_row + jrow + warp_id < outRows) && (base_row+warp_lane < rows))
27792779
{
2780-
// each row hae 32 columns and is offset by 1 to prevent bank conflict during storage into smem
2780+
// each row has 32 columns and is offset by 1 to prevent bank conflict during storage into smem
27812781
char data = smem_data[(subrow_loop_row + jrow + warp_id)*33 + warp_lane];
27822782

27832783
// each 32 columns we have new tile

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ ignore = [
3131
"F841", # Local assigned but not used (TODO: enable, these are likely bugs)
3232
"RUF012", # Mutable class attribute annotations
3333
]
34-
ignore-init-module-imports = true # allow to expose in __init__.py via imports
3534

3635
[tool.ruff.lint.extend-per-file-ignores]
3736
"**/__init__.py" = ["F401"] # allow unused imports in __init__.py

0 commit comments

Comments
 (0)