Skip to content

Commit ac00641

Browse files
danthe3rdxFormers Bot
authored andcommitted
Bump version to 0.0.32 (fairinternal/xformers#1418)
__original_commit__ = fairinternal/xformers@dee2011
1 parent 635a8ab commit ac00641

File tree

10 files changed

+35
-22
lines changed

10 files changed

+35
-22
lines changed

.github/actions/setup-build-cuda/action.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,10 @@ runs:
2424
print(sys.version)
2525
cushort = "${{ inputs.toolkit_short_version }}"
2626
# Version uploaded to pypi (rather than PyTorch s3)
27-
TORCH_CUDA_DEFAULT = "126" # since pytorch 2.7.0
27+
TORCH_CUDA_DEFAULT = "128" # since pytorch 2.8.0
2828
# https://github.com/Jimver/cuda-toolkit/blob/master/src/links/linux-links.ts
2929
full_version, install_script = {
30+
"129": ("12.9.0", "https://developer.download.nvidia.com/compute/cuda/12.9.1/local_installers/cuda_12.9.1_575.57.08_linux.run"),
3031
"128": ("12.8.1", "https://developer.download.nvidia.com/compute/cuda/12.8.1/local_installers/cuda_12.8.1_570.124.06_linux.run"),
3132
# (Build with nvcc 12.8 on linux even when building for 12.6 to avoid seg fault in Flash3 build)
3233
"126": ("12.8.1", "https://developer.download.nvidia.com/compute/cuda/12.8.1/local_installers/cuda_12.8.1_570.124.06_linux.run"),
@@ -35,6 +36,7 @@ runs:
3536
"6.1": ("6.1.2", "https://repo.radeon.com/amdgpu-install/6.1.3/rhel/8.9/amdgpu-install-6.1.60103-1.el8.noarch.rpm"),
3637
"6.2.4": ("6.2.4", "https://repo.radeon.com/amdgpu-install/6.2.4/rhel/8.9/amdgpu-install-6.2.60204-1.el8.noarch.rpm"),
3738
"6.3": ("6.3.1", "https://repo.radeon.com/amdgpu-install/6.3.1/rhel/8.9/amdgpu-install-6.3.60301-1.el8.noarch.rpm"),
39+
"6.4": ("6.4.2", "https://repo.radeon.com/amdgpu-install/6.4.2/rhel/8.9/amdgpu-install-6.4.60402-1.el8.noarch.rpm"),
3840
}[cushort]
3941
with open(os.environ['GITHUB_OUTPUT'], "r+") as fp:
4042
fp.write("CUDA_VERSION=" + full_version + "\n")
@@ -50,7 +52,7 @@ runs:
5052
- name: Install cuda
5153
if: runner.os == 'Windows' && inputs.toolkit_type == 'cuda'
5254
id: cuda-toolkit
53-
uses: Jimver/[email protected].23
55+
uses: Jimver/[email protected].24
5456
with:
5557
cuda: ${{ steps.cuda_info.outputs.CUDA_VERSION }}
5658
method: network

.github/workflows/rocm_build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ jobs:
2222
matrix:
2323
os: ['ubuntu-alola']
2424
python: ['3.11']
25-
torch_version: ['2.7.1']
25+
torch_version: ['2.8.0']
2626
toolkit_type: ['rocm']
27-
toolkit_short_version: ['6.2.4', '6.3']
27+
toolkit_short_version: ['6.3', '6.4']
2828

2929
uses: ./.github/workflows/wheels_build.yml
3030
if: github.repository == 'rocm/xformers'

.github/workflows/wheels.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,12 @@ jobs:
3333
PYTHON_VERSION = "3.9"
3434
# NOTE: Don't forget to update `upload_pt`'s matrix
3535
# when changing the CUDA/ROCM versions below!
36-
CU_VERSIONS = ['118', '126', '128']
37-
ROCM_VERSIONS = ["6.2.4", "6.3"]
36+
CU_VERSIONS = ['126', '128', '129']
37+
ROCM_VERSIONS = ['6.3', '6.4']
3838
3939
include = []
4040
for os in ['8-core-ubuntu', 'windows-8-core']:
41-
for torch_version in ['2.7.1']:
41+
for torch_version in ['2.8.0']:
4242
# CUDA builds
4343
for cuda_short_version in CU_VERSIONS:
4444
if cuda_short_version < "124" and "windows" in os:
@@ -88,7 +88,7 @@ jobs:
8888
uses: ./.github/workflows/wheels_upload_pip.yml
8989
with:
9090
twine_username: __token__
91-
filter: "*torch2.7.1+cu126*"
91+
filter: "*torch2.8.0+cu128*"
9292
execute: ${{ github.repository == 'facebookresearch/xformers' && github.event_name != 'pull_request' }}
9393
secrets:
9494
twine_password: ${{ secrets.PYPI_TOKEN }}
@@ -99,15 +99,15 @@ jobs:
9999
fail-fast: false
100100
matrix:
101101
suffix:
102-
- cu118
103102
- cu126
104103
- cu128
104+
- cu129
105105
- rocm6.2.4
106106
- rocm6.3
107107
uses: ./.github/workflows/wheels_upload_s3.yml
108108
with:
109109
aws_role: "arn:aws:iam::749337293305:role/pytorch_bot_uploader_role"
110110
s3_path: s3://pytorch/whl/${{ matrix.suffix }}/
111111
aws_s3_cp_extra_args: --acl public-read
112-
filter: "*torch2.7.1+${{ matrix.suffix }}*"
112+
filter: "*torch2.8.0+${{ matrix.suffix }}*"
113113
execute: ${{ github.repository == 'facebookresearch/xformers' && github.ref_type == 'tag' }}

.github/workflows/win-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ jobs:
7373
7474
- name: Install build dependencies
7575
run: |
76-
$PY -m pip install wheel setuptools ninja torch==2.7.1 -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cu126
76+
$PY -m pip install wheel setuptools ninja torch==2.8.0 -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cu126
7777
git config --global --add safe.directory "*"
7878
$PY -c "import torch; print('torch', torch.__version__)"
7979
$PY -c "import torch; print('torch.cuda', torch.version.cuda)"

CHANGELOG.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,20 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7-
## [0.0.32] - 2025-??-??
7+
## [0.0.33] - 2025-??-??
8+
9+
## [0.0.32] - 2025-08-13
10+
Pre-built binary wheels are available for PyTorch 2.8.0.
11+
12+
### Added
13+
- Support flash-attention package up to 2.8.2
14+
- Speed improvements to `python -m xformers.profiler.find_slowest`
15+
816
### Removed
917
- Removed autograd backward pass for merge_attentions as it is easy to use incorrectly.
18+
- Attention biases are no longer `torch.Tensor` subclasses. This is no longer
19+
necessary for torch.compile to work, and was adding more complexity
20+
1021

1122
## [0.0.31] - 2025-06-25
1223
Pre-built binary wheels are available for PyTorch 2.7.1.

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# Example requirement, can be anything that pip knows
22
# install with `pip install -r requirements.txt`, and make sure that CI does the same
3-
torch >= 2.7
3+
torch >= 2.8
44
numpy

version.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.0.32
1+
0.0.33

xformers/ops/fmha/flash.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474

7575
FLASH_VERSION = flash_attn.__version__
7676
FLASH_VER_MIN = parse_version("2.7.1")
77-
FLASH_VER_LAST = parse_version("2.8.0.post2") # last supported, inclusive
77+
FLASH_VER_LAST = parse_version("2.8.2") # last supported, inclusive
7878
flash_ver_parsed = parse_version(FLASH_VERSION)
7979
if (
8080
flash_ver_parsed < FLASH_VER_MIN or flash_ver_parsed > FLASH_VER_LAST

xformers/ops/fmha/flash3.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def _flash_attention3_incompatible_reason() -> Optional[str]:
7171
torch.ops.flash_attn_3, "bwd"
7272
):
7373
return "PyTorch has no `flash_attn_3` - is your Flash-Attention version recent enough?"
74-
if not torch.ops.flash_attn_3.fwd.default._schema.is_backward_compatible_with(
74+
if not torch.ops.flash_attn_3.fwd.default._schema.is_backward_compatible_with( # type: ignore
7575
parse_schema(
7676
"flash_attn_3::fwd(Tensor q, Tensor k, Tensor v, Tensor(k_new!)? k_new=None, "
7777
"Tensor(v_new!)? v_new=None, Tensor? q_v=None, Tensor(out!)? out=None, "
@@ -87,7 +87,7 @@ def _flash_attention3_incompatible_reason() -> Optional[str]:
8787
)
8888
):
8989
return "flash_attn_3::fwd operator is not compatible"
90-
if not torch.ops.flash_attn_3.bwd.default._schema.is_backward_compatible_with(
90+
if not torch.ops.flash_attn_3.bwd.default._schema.is_backward_compatible_with( # type: ignore
9191
parse_schema(
9292
"flash_attn_3::bwd(Tensor dout, Tensor q, Tensor k, Tensor v, Tensor out, Tensor softmax_lse, "
9393
"Tensor(dq!)? dq=None, Tensor(dk!)? dk=None, Tensor(dv!)? dv=None, Tensor? cu_seqlens_q=None, "

xformers/ops/fmha/torch_attention_compat.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def is_pt_cutlass_compatible(force: bool = False) -> bool:
2727
expected_fwd_schema = parse_schema(fwd_schema_str)
2828

2929
current_schema = torch.ops.aten._efficient_attention_forward.default._schema
30-
if not current_schema.is_backward_compatible_with(expected_fwd_schema):
30+
if not current_schema.is_backward_compatible_with(expected_fwd_schema): # type: ignore
3131
compatible = False
3232

3333
if force:
@@ -48,7 +48,7 @@ def is_pt_cutlass_compatible(force: bool = False) -> bool:
4848
expected_bwd_schema = parse_schema(bwd_schema_str)
4949

5050
current_schema = torch.ops.aten._efficient_attention_backward.default._schema
51-
if not current_schema.is_backward_compatible_with(expected_bwd_schema):
51+
if not current_schema.is_backward_compatible_with(expected_bwd_schema): # type: ignore
5252
compatible = False
5353

5454
if force:
@@ -108,8 +108,8 @@ def is_pt_flash_old(force: bool) -> Optional[bool]:
108108
expected_old_fwd_schema = parse_schema(old_fwd_schema_str)
109109

110110
current_schema = torch.ops.aten._flash_attention_forward.default._schema
111-
old = current_schema.is_backward_compatible_with(expected_old_fwd_schema)
112-
if not old and not current_schema.is_backward_compatible_with(expected_fwd_schema):
111+
old = current_schema.is_backward_compatible_with(expected_old_fwd_schema) # type: ignore
112+
if not old and not current_schema.is_backward_compatible_with(expected_fwd_schema): # type: ignore
113113
compatible = False
114114

115115
if force:
@@ -136,7 +136,7 @@ def is_pt_flash_old(force: bool) -> Optional[bool]:
136136
expected_bwd_schema = parse_schema(bwd_schema_old_str if old else bwd_schema_str)
137137

138138
current_schema = torch.ops.aten._flash_attention_backward.default._schema
139-
if not current_schema.is_backward_compatible_with(expected_bwd_schema):
139+
if not current_schema.is_backward_compatible_with(expected_bwd_schema): # type: ignore
140140
compatible = False
141141

142142
if force:

0 commit comments

Comments
 (0)