Skip to content

Commit d63e3d5

Browse files
committed
Merge remote-tracking branch 'origin/main' into remove_boilerplate_code
2 parents f872136 + 70be245 commit d63e3d5

24 files changed

+1155
-124
lines changed

.github/workflows/doc_build.yml

+3
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ on:
99
tags:
1010
- v[0-9]+.[0-9]+.[0-9]
1111
- v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+
12+
paths:
13+
- 'docs/**'
14+
- '!docs/**'
1215
pull_request:
1316
workflow_dispatch:
1417

.github/workflows/float8_test.yml

+7-2
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,14 @@ jobs:
2525
include:
2626
- name: SM-89
2727
runs-on: linux.g6.4xlarge.experimental.nvidia.gpu
28-
torch-spec: '--pre torch --index-url https://download.pytorch.org/whl/nightly/cu121'
28+
torch-spec: '--pre torch==2.7.0.dev20250122 --index-url https://download.pytorch.org/whl/nightly/cu124'
2929
gpu-arch-type: "cuda"
30-
gpu-arch-version: "12.1"
30+
gpu-arch-version: "12.4"
31+
- name: H100
32+
runs-on: linux.aws.h100
33+
torch-spec: '--pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu124'
34+
gpu-arch-type: "cuda"
35+
gpu-arch-version: "12.4"
3136

3237
permissions:
3338
id-token: write
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Run Float8nocompile Tests
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- 'gh/**'
8+
paths:
9+
- 'torchao/prototype/float8nocompile/**'
10+
- '!torchao/prototype/float8nocompile/**'
11+
pull_request:
12+
branches:
13+
- main
14+
- 'gh/**'
15+
paths:
16+
- 'torchao/prototype/float8nocompile/**'
17+
- '!torchao/prototype/float8nocompile/**'
18+
19+
concurrency:
20+
group: floatnocompile_test-${{ github.workflow }}-${{ github.ref == 'refs/heads/main' && github.run_number || github.ref }}
21+
cancel-in-progress: true
22+
23+
env:
24+
HF_TOKEN: ${{ secrets.HF_TOKEN }}
25+
26+
jobs:
27+
test:
28+
strategy:
29+
fail-fast: false
30+
matrix:
31+
include:
32+
- name: SM-89
33+
runs-on: linux.g6.4xlarge.experimental.nvidia.gpu
34+
torch-spec: '--pre torch --index-url https://download.pytorch.org/whl/nightly/cu121'
35+
gpu-arch-type: "cuda"
36+
gpu-arch-version: "12.1"
37+
38+
uses: pytorch/test-infra/.github/workflows/linux_job_v2.yml@main
39+
with:
40+
timeout: 300
41+
runner: ${{ matrix.runs-on }}
42+
gpu-arch-type: ${{ matrix.gpu-arch-type }}
43+
gpu-arch-version: ${{ matrix.gpu-arch-version }}
44+
submodules: recursive
45+
script: |
46+
conda create -n venv python=3.9 -y
47+
conda activate venv
48+
export PATH=/opt/rh/devtoolset-10/root/usr/bin/:$PATH
49+
python -m pip install --upgrade pip
50+
pip install ${{ matrix.torch-spec }}
51+
pip install -r dev-requirements.txt
52+
pip install .
53+
cd torchao/prototype/float8nocompile
54+
pytest kernels/ --verbose -s
55+
pytest test/train_test.py --verbose -s

.github/workflows/nightly_smoke_test.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ jobs:
2121
include:
2222
- name: CUDA Nightly
2323
runs-on: linux.g5.12xlarge.nvidia.gpu
24-
torch-spec: '--pre torch --index-url https://download.pytorch.org/whl/nightly/cu121'
24+
torch-spec: '--pre torch==2.7.0.dev20250122 --index-url https://download.pytorch.org/whl/nightly/cu124'
2525
gpu-arch-type: "cuda"
26-
gpu-arch-version: "12.1"
26+
gpu-arch-version: "12.4"
2727

2828
permissions:
2929
id-token: write

.github/workflows/regression_test.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ jobs:
2525
include:
2626
- name: CUDA Nightly
2727
runs-on: linux.g5.12xlarge.nvidia.gpu
28-
torch-spec: '--pre torch --index-url https://download.pytorch.org/whl/nightly/cu124'
28+
torch-spec: '--pre torch==2.7.0.dev20250122 --index-url https://download.pytorch.org/whl/nightly/cu124'
2929
gpu-arch-type: "cuda"
3030
gpu-arch-version: "12.4"
3131
- name: CPU Nightly
3232
runs-on: linux.4xlarge
33-
torch-spec: '--pre torch --index-url https://download.pytorch.org/whl/nightly/cpu'
33+
torch-spec: '--pre torch==2.7.0.dev20250122 --index-url https://download.pytorch.org/whl/nightly/cpu'
3434
gpu-arch-type: "cpu"
3535
gpu-arch-version: ""
3636

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ docs/dev
262262
docs/build
263263
docs/source/tutorials/*
264264
docs/source/gen_modules/*
265-
docs/source/sg_execution_times
265+
docs/source/sg_execution_times.rst
266266

267267
# LevelDB files
268268
*.sst

docs/source/_templates/layout.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
{% block sidebartitle %}
44
<div class="version">
5-
<a href='tba'>{{ version }} &#x25BC</a>
5+
<a href='index.html'>{{ version }} &#x25BC</a>
66
</div>
77
{% include "searchbox.html" %}
88
{% endblock %}
@@ -22,7 +22,7 @@
2222
// to point to the torchao repo.
2323
var overwrite = function (_) {
2424
if ($(this).length > 0) {
25-
$(this)[0].href = "https://github.com/pytorch-labs/ao"
25+
$(this)[0].href = "https://github.com/pytorch/ao"
2626
}
2727
}
2828
// PC

docs/source/contributor_guide.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
torchao Contributor Guide
1+
Contributor Guide
22
-------------------------
33

44
.. toctree::

docs/source/getting-started.rst

-4
This file was deleted.

docs/source/index.rst

+17-83
Original file line numberDiff line numberDiff line change
@@ -1,82 +1,26 @@
11
Welcome to the torchao Documentation
2-
=======================================
2+
====================================
33

4-
`torchao <https://github.com/pytorch/ao>`__ is a library for custom data types & optimizations. Quantize and sparsify weights, gradients, optimizers & activations for inference and training using native PyTorch. Please checkout torchao `README <https://github.com/pytorch/ao#torchao-pytorch-architecture-optimization>`__ for an overall introduction to the library and recent highlight and updates. The documentation here will focus on:
4+
`torchao <https://github.com/pytorch/ao>`__ is a library for custom data types and optimizations.
5+
Quantize and sparsify weights, gradients, optimizers, and activations for inference and training
6+
using native PyTorch. Please checkout torchao `README <https://github.com/pytorch/ao#torchao-pytorch-architecture-optimization>`__
7+
for an overall introduction to the library and recent highlight and updates.
58

6-
1. API Reference
7-
2. Developer Contribution Guide
8-
3. Tutorials
9-
10-
..
11-
.. grid:: 3
12-
13-
.. grid-item-card:: :octicon:`file-code;1em`
14-
Getting Started
15-
:img-top: _static/img/card-background.svg
16-
:link: getting-started.html
17-
:link-type: url
18-
19-
Learn about how to get started with torchao
20-
and ts application in your projects.
21-
22-
.. grid-item-card:: :octicon:`file-code;1em`
23-
Concepts
24-
:img-top: _static/img/card-background.svg
25-
:link: dtypes.html
26-
:link-type: url
27-
28-
Learn about the key torchao concepts such
29-
as dtypes, quantization, sparsity, among others.
30-
31-
.. grid-item-card:: :octicon:`file-code;1em`
32-
API Reference
33-
:img-top: _static/img/card-background.svg
34-
:link: api_ref_intro.html
35-
:link-type: url
36-
37-
A comprehensive reference for the torchao
38-
API and its functionalities.
39-
40-
Tutorials
41-
~~~~~~~~~
42-
43-
Ready to experiment? Check out some of the
44-
torchao tutorials.
45-
46-
.. customcardstart::
47-
48-
.. customcarditem::
49-
:header: Template Tutorial
50-
:card_description: A placeholder template for demo purposes
51-
:image: _static/img/generic-pytorch-logo.png
52-
:link: tutorials/template_tutorial.html
53-
:tags: template
54-
55-
.. customcardend::
56-
57-
58-
.. ----------------------------------------------------------------------
59-
.. Below is the toctree i.e. it defines the content of the left sidebar.
60-
.. Each of the entry below corresponds to a file.rst in docs/source/.
61-
.. ----------------------------------------------------------------------
62-
63-
..
64-
.. toctree::
65-
:glob:
66-
:maxdepth: 1
67-
:caption: Getting Started
68-
:hidden:
9+
.. toctree::
10+
:glob:
11+
:maxdepth: 1
12+
:caption: Getting Started
6913

70-
overview
71-
getting-started
14+
quick_start
7215

73-
.. toctree::
74-
:glob:
75-
:maxdepth: 1
76-
:caption: Tutorials
77-
:hidden:
16+
.. toctree::
17+
:glob:
18+
:maxdepth: 1
19+
:caption: Developer Notes
7820

79-
tutorials/template_tutorial
21+
quantization
22+
sparsity
23+
contributor_guide
8024

8125
.. toctree::
8226
:glob:
@@ -86,20 +30,10 @@ Welcome to the torchao Documentation
8630
api_ref_dtypes
8731
api_ref_quantization
8832
api_ref_sparsity
89-
..
90-
api_ref_kernel
91-
92-
.. toctree::
93-
:glob:
94-
:maxdepth: 1
95-
:caption: Contributor Guide
96-
97-
contributor_guide
9833

9934
.. toctree::
10035
:glob:
10136
:maxdepth: 1
10237
:caption: Tutorials
10338

10439
serialization
105-

docs/source/overview.rst

-4
This file was deleted.

docs/source/quantization.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Quantization
2-
============
1+
Quantization Overview
2+
---------------------
33

4-
TBA
4+
Coming soon!

0 commit comments

Comments
 (0)