tensorstudio 0.1.0__tar.gz → 1.0.0rc2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- tensorstudio-1.0.0rc2/.github/workflows/ci.yml +92 -0
- tensorstudio-1.0.0rc2/.github/workflows/publish-testpypi.yml +108 -0
- tensorstudio-1.0.0rc2/.github/workflows/publish.yml +107 -0
- tensorstudio-1.0.0rc2/.github/workflows/wheels.yml +90 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/.gitignore +5 -0
- tensorstudio-1.0.0rc2/CHANGELOG.md +40 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/CMakeLists.txt +1 -1
- tensorstudio-1.0.0rc2/PKG-INFO +336 -0
- tensorstudio-1.0.0rc2/README.md +278 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/SECURITY.md +2 -2
- tensorstudio-1.0.0rc2/benchmarks/bench_activations.py +13 -0
- tensorstudio-1.0.0rc2/benchmarks/bench_autograd.py +13 -0
- tensorstudio-1.0.0rc2/benchmarks/bench_elementwise.py +13 -0
- tensorstudio-1.0.0rc2/benchmarks/bench_matmul.py +13 -0
- tensorstudio-1.0.0rc2/benchmarks/bench_reductions.py +13 -0
- tensorstudio-1.0.0rc2/benchmarks/bench_tensor_ops.py +14 -0
- tensorstudio-1.0.0rc2/benchmarks/bench_training_loop.py +13 -0
- tensorstudio-1.0.0rc2/benchmarks/benchmark_report.py +699 -0
- tensorstudio-1.0.0rc2/benchmarks/results.md +214 -0
- tensorstudio-1.0.0rc2/benchmarks/results_matmul.md +38 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Autograde/index.md +6 -1
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Benchmarks/index.md +2 -2
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Hardware/cpu-backend.md +4 -3
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Neural Networks/modules.md +2 -3
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Neural Networks/training.md +1 -1
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Roadmap/index.md +3 -5
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Usage/serialization.md +4 -3
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Usage/tensors.md +8 -2
- tensorstudio-1.0.0rc2/docs/api.md +186 -0
- tensorstudio-1.0.0rc2/docs/autograd.md +110 -0
- tensorstudio-1.0.0rc2/docs/data.md +74 -0
- tensorstudio-1.0.0rc2/docs/development.md +120 -0
- tensorstudio-1.0.0rc2/docs/index.md +70 -0
- tensorstudio-1.0.0rc2/docs/linux.md +58 -0
- tensorstudio-1.0.0rc2/docs/macos.md +64 -0
- tensorstudio-1.0.0rc2/docs/nn.md +172 -0
- tensorstudio-1.0.0rc2/docs/optim.md +118 -0
- tensorstudio-1.0.0rc2/docs/publishing.md +115 -0
- tensorstudio-1.0.0rc2/docs/quickstart.md +177 -0
- tensorstudio-1.0.0rc2/docs/serialization.md +51 -0
- tensorstudio-1.0.0rc2/docs/tensors.md +165 -0
- tensorstudio-1.0.0rc2/docs/windows.md +74 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/autograd.hpp +2 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/ops.hpp +14 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/random.hpp +2 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/tensor.hpp +2 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/version.hpp +1 -1
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/mkdocs.yml +10 -11
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/pyproject.toml +10 -5
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/_C.pyi +36 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/__init__.py +60 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/_version.py +1 -1
- tensorstudio-1.0.0rc2/python/tensorstudio/data/dataloader.py +66 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/data/dataset.py +8 -6
- tensorstudio-1.0.0rc2/python/tensorstudio/grad_mode.py +35 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/nn/__init__.py +63 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/nn/functional.py +75 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/nn/losses.py +60 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/nn/modules.py +346 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/ops.py +60 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/optim/__init__.py +10 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/optim/adam.py +103 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/optim/adamw.py +7 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/optim/lr_scheduler.py +65 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/optim/sgd.py +72 -0
- tensorstudio-1.0.0rc2/python/tensorstudio/optim/utils.py +48 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/serialization.py +3 -3
- tensorstudio-1.0.0rc2/python/tensorstudio/tensor.py +250 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/bindings/bind_autograd.cpp +2 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/bindings/bind_ops.cpp +11 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/bindings/bind_tensor.cpp +44 -4
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/autograd.cpp +16 -0
- tensorstudio-1.0.0rc2/src/core/ops.cpp +1093 -0
- tensorstudio-1.0.0rc2/src/core/random.cpp +54 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/serialization.cpp +1 -1
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/tensor.cpp +38 -6
- tensorstudio-1.0.0rc2/tests/test_autograd.py +123 -0
- tensorstudio-1.0.0rc2/tests/test_data.py +36 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/tests/test_import.py +2 -1
- tensorstudio-1.0.0rc2/tests/test_nn.py +127 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/tests/test_ops.py +19 -1
- tensorstudio-1.0.0rc2/tests/test_optim.py +116 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/tests/test_serialization.py +12 -0
- tensorstudio-1.0.0rc2/tests/test_tensor.py +139 -0
- tensorstudio-0.1.0/.github/workflows/ci.yml +0 -31
- tensorstudio-0.1.0/.github/workflows/publish.yml +0 -39
- tensorstudio-0.1.0/.github/workflows/wheels.yml +0 -45
- tensorstudio-0.1.0/CHANGELOG.md +0 -9
- tensorstudio-0.1.0/PKG-INFO +0 -188
- tensorstudio-0.1.0/README.md +0 -130
- tensorstudio-0.1.0/benchmarks/bench_matmul.py +0 -28
- tensorstudio-0.1.0/benchmarks/bench_tensor_ops.py +0 -31
- tensorstudio-0.1.0/docs/api.md +0 -164
- tensorstudio-0.1.0/docs/development.md +0 -120
- tensorstudio-0.1.0/docs/index.md +0 -55
- tensorstudio-0.1.0/docs/publishing.md +0 -101
- tensorstudio-0.1.0/docs/quickstart.md +0 -115
- tensorstudio-0.1.0/python/tensorstudio/__init__.py +0 -24
- tensorstudio-0.1.0/python/tensorstudio/data/dataloader.py +0 -38
- tensorstudio-0.1.0/python/tensorstudio/nn/__init__.py +0 -22
- tensorstudio-0.1.0/python/tensorstudio/nn/functional.py +0 -25
- tensorstudio-0.1.0/python/tensorstudio/nn/losses.py +0 -18
- tensorstudio-0.1.0/python/tensorstudio/nn/modules.py +0 -150
- tensorstudio-0.1.0/python/tensorstudio/optim/__init__.py +0 -8
- tensorstudio-0.1.0/python/tensorstudio/optim/adam.py +0 -53
- tensorstudio-0.1.0/python/tensorstudio/optim/sgd.py +0 -31
- tensorstudio-0.1.0/python/tensorstudio/tensor.py +0 -69
- tensorstudio-0.1.0/src/core/ops.cpp +0 -448
- tensorstudio-0.1.0/src/core/random.cpp +0 -18
- tensorstudio-0.1.0/tests/test_autograd.py +0 -61
- tensorstudio-0.1.0/tests/test_nn.py +0 -41
- tensorstudio-0.1.0/tests/test_optim.py +0 -39
- tensorstudio-0.1.0/tests/test_tensor.py +0 -50
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/.pre-commit-config.yaml +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/CONTRIBUTING.md +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/LICENSE +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/docs/Usage/numpy-interop.md +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/examples/basic_tensor_ops.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/examples/linear_regression.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/examples/save_load_model.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/examples/tiny_mlp.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/device.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/dtype.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/errors.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/module.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/optim.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/serialization.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/shape.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/include/tensorstudio/storage.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/autograd.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/data/__init__.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/errors.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/py.typed +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/python/tensorstudio/typing.py +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/bindings/bind_nn.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/bindings/bind_optim.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/bindings/bindings.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/bindings/bindings.hpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/device.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/dtype.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/errors.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/module.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/optim.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/shape.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/src/core/storage.cpp +0 -0
- {tensorstudio-0.1.0 → tensorstudio-1.0.0rc2}/tests/test_numpy_interop.py +0 -0
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
pull_request:
|
|
6
|
+
|
|
7
|
+
jobs:
|
|
8
|
+
windows:
|
|
9
|
+
name: Windows py${{ matrix.python-version }}
|
|
10
|
+
runs-on: windows-latest
|
|
11
|
+
strategy:
|
|
12
|
+
fail-fast: false
|
|
13
|
+
matrix:
|
|
14
|
+
python-version: ["3.10", "3.11", "3.12", "3.13"]
|
|
15
|
+
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
- uses: actions/setup-python@v5
|
|
19
|
+
with:
|
|
20
|
+
python-version: ${{ matrix.python-version }}
|
|
21
|
+
- name: Install editable package
|
|
22
|
+
run: |
|
|
23
|
+
python -m pip install -U pip
|
|
24
|
+
python -m pip install -e ".[dev]"
|
|
25
|
+
- name: Import native extension
|
|
26
|
+
run: python -c "import tensorstudio as ts; import tensorstudio._C; print(ts.__version__); print(ts.ones((2, 2)) + 1)"
|
|
27
|
+
- name: Ruff
|
|
28
|
+
run: ruff check .
|
|
29
|
+
- name: Mypy
|
|
30
|
+
run: mypy --python-version ${{ matrix.python-version }} python/tensorstudio
|
|
31
|
+
- name: Tests
|
|
32
|
+
run: pytest -q
|
|
33
|
+
- name: Example
|
|
34
|
+
run: python examples/basic_tensor_ops.py
|
|
35
|
+
|
|
36
|
+
linux:
|
|
37
|
+
name: Linux py${{ matrix.python-version }}
|
|
38
|
+
runs-on: ubuntu-latest
|
|
39
|
+
needs: windows
|
|
40
|
+
strategy:
|
|
41
|
+
fail-fast: false
|
|
42
|
+
matrix:
|
|
43
|
+
python-version: ["3.10", "3.11", "3.12", "3.13"]
|
|
44
|
+
|
|
45
|
+
steps:
|
|
46
|
+
- uses: actions/checkout@v4
|
|
47
|
+
- uses: actions/setup-python@v5
|
|
48
|
+
with:
|
|
49
|
+
python-version: ${{ matrix.python-version }}
|
|
50
|
+
- name: Install editable package
|
|
51
|
+
run: |
|
|
52
|
+
python -m pip install -U pip
|
|
53
|
+
python -m pip install -e ".[dev]"
|
|
54
|
+
- name: Import native extension
|
|
55
|
+
run: python -c "import tensorstudio as ts; import tensorstudio._C; print(ts.__version__)"
|
|
56
|
+
- name: Ruff
|
|
57
|
+
run: ruff check .
|
|
58
|
+
- name: Mypy
|
|
59
|
+
run: mypy --python-version ${{ matrix.python-version }} python/tensorstudio
|
|
60
|
+
- name: Tests
|
|
61
|
+
run: pytest -q
|
|
62
|
+
- name: Example
|
|
63
|
+
run: python examples/basic_tensor_ops.py
|
|
64
|
+
|
|
65
|
+
macos:
|
|
66
|
+
name: macOS py${{ matrix.python-version }}
|
|
67
|
+
runs-on: macos-latest
|
|
68
|
+
needs: linux
|
|
69
|
+
strategy:
|
|
70
|
+
fail-fast: false
|
|
71
|
+
matrix:
|
|
72
|
+
python-version: ["3.10", "3.11", "3.12", "3.13"]
|
|
73
|
+
|
|
74
|
+
steps:
|
|
75
|
+
- uses: actions/checkout@v4
|
|
76
|
+
- uses: actions/setup-python@v5
|
|
77
|
+
with:
|
|
78
|
+
python-version: ${{ matrix.python-version }}
|
|
79
|
+
- name: Install editable package
|
|
80
|
+
run: |
|
|
81
|
+
python -m pip install -U pip
|
|
82
|
+
python -m pip install -e ".[dev]"
|
|
83
|
+
- name: Import native extension
|
|
84
|
+
run: python -c "import tensorstudio as ts; import tensorstudio._C; print(ts.__version__)"
|
|
85
|
+
- name: Ruff
|
|
86
|
+
run: ruff check .
|
|
87
|
+
- name: Mypy
|
|
88
|
+
run: mypy --python-version ${{ matrix.python-version }} python/tensorstudio
|
|
89
|
+
- name: Tests
|
|
90
|
+
run: pytest -q
|
|
91
|
+
- name: Example
|
|
92
|
+
run: python examples/basic_tensor_ops.py
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
name: Publish TestPyPI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
|
|
6
|
+
permissions:
|
|
7
|
+
contents: read
|
|
8
|
+
id-token: write
|
|
9
|
+
|
|
10
|
+
env:
|
|
11
|
+
CIBW_BUILD: "cp310-* cp311-* cp312-* cp313-*"
|
|
12
|
+
CIBW_SKIP: "*-musllinux*"
|
|
13
|
+
CIBW_MANYLINUX_X86_64_IMAGE: "manylinux_2_28"
|
|
14
|
+
CIBW_TEST_COMMAND: >-
|
|
15
|
+
python -c "import tensorstudio as ts; import tensorstudio._C; x = ts.ones((2, 2), requires_grad=True); y = ((x * 2.0) + 1.0).sum(); y.backward(); assert x.grad.tolist() == [[2.0, 2.0], [2.0, 2.0]]"
|
|
16
|
+
|
|
17
|
+
jobs:
|
|
18
|
+
windows_wheels:
|
|
19
|
+
name: Windows wheels
|
|
20
|
+
runs-on: windows-latest
|
|
21
|
+
steps:
|
|
22
|
+
- uses: actions/checkout@v4
|
|
23
|
+
- uses: actions/setup-python@v5
|
|
24
|
+
with:
|
|
25
|
+
python-version: "3.12"
|
|
26
|
+
- name: Build Windows wheels
|
|
27
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
28
|
+
env:
|
|
29
|
+
CIBW_ARCHS_WINDOWS: "AMD64"
|
|
30
|
+
- uses: actions/upload-artifact@v4
|
|
31
|
+
with:
|
|
32
|
+
name: dist-windows
|
|
33
|
+
path: wheelhouse/*.whl
|
|
34
|
+
|
|
35
|
+
linux_wheels:
|
|
36
|
+
name: Linux wheels
|
|
37
|
+
runs-on: ubuntu-latest
|
|
38
|
+
needs: windows_wheels
|
|
39
|
+
steps:
|
|
40
|
+
- uses: actions/checkout@v4
|
|
41
|
+
- uses: actions/setup-python@v5
|
|
42
|
+
with:
|
|
43
|
+
python-version: "3.12"
|
|
44
|
+
- name: Build Linux wheels
|
|
45
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
46
|
+
env:
|
|
47
|
+
CIBW_ARCHS_LINUX: "x86_64"
|
|
48
|
+
- uses: actions/upload-artifact@v4
|
|
49
|
+
with:
|
|
50
|
+
name: dist-linux
|
|
51
|
+
path: wheelhouse/*.whl
|
|
52
|
+
|
|
53
|
+
macos_wheels:
|
|
54
|
+
name: macOS wheels
|
|
55
|
+
runs-on: macos-latest
|
|
56
|
+
needs: linux_wheels
|
|
57
|
+
steps:
|
|
58
|
+
- uses: actions/checkout@v4
|
|
59
|
+
- uses: actions/setup-python@v5
|
|
60
|
+
with:
|
|
61
|
+
python-version: "3.12"
|
|
62
|
+
- name: Build macOS wheels
|
|
63
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
64
|
+
env:
|
|
65
|
+
CIBW_ARCHS_MACOS: "auto"
|
|
66
|
+
- uses: actions/upload-artifact@v4
|
|
67
|
+
with:
|
|
68
|
+
name: dist-macos
|
|
69
|
+
path: wheelhouse/*.whl
|
|
70
|
+
|
|
71
|
+
build_sdist:
|
|
72
|
+
name: Build sdist
|
|
73
|
+
runs-on: ubuntu-latest
|
|
74
|
+
needs: macos_wheels
|
|
75
|
+
steps:
|
|
76
|
+
- uses: actions/checkout@v4
|
|
77
|
+
- uses: actions/setup-python@v5
|
|
78
|
+
with:
|
|
79
|
+
python-version: "3.12"
|
|
80
|
+
- name: Build sdist
|
|
81
|
+
run: |
|
|
82
|
+
python -m pip install -U build twine
|
|
83
|
+
python -m build --sdist
|
|
84
|
+
python -m twine check dist/*
|
|
85
|
+
- uses: actions/upload-artifact@v4
|
|
86
|
+
with:
|
|
87
|
+
name: dist-sdist
|
|
88
|
+
path: dist/*.tar.gz
|
|
89
|
+
|
|
90
|
+
publish:
|
|
91
|
+
name: Publish to TestPyPI
|
|
92
|
+
needs: [windows_wheels, linux_wheels, macos_wheels, build_sdist]
|
|
93
|
+
runs-on: ubuntu-latest
|
|
94
|
+
environment: testpypi
|
|
95
|
+
steps:
|
|
96
|
+
- uses: actions/download-artifact@v4
|
|
97
|
+
with:
|
|
98
|
+
pattern: dist-*
|
|
99
|
+
path: dist
|
|
100
|
+
merge-multiple: true
|
|
101
|
+
- name: Verify artifacts
|
|
102
|
+
run: |
|
|
103
|
+
python -m pip install -U twine
|
|
104
|
+
python -m twine check dist/*
|
|
105
|
+
- name: Publish to TestPyPI
|
|
106
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
107
|
+
with:
|
|
108
|
+
repository-url: https://test.pypi.org/legacy/
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
name: Publish
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
release:
|
|
6
|
+
types: [published]
|
|
7
|
+
push:
|
|
8
|
+
tags:
|
|
9
|
+
- "v1.0.0"
|
|
10
|
+
|
|
11
|
+
permissions:
|
|
12
|
+
contents: read
|
|
13
|
+
id-token: write
|
|
14
|
+
|
|
15
|
+
env:
|
|
16
|
+
CIBW_BUILD: "cp310-* cp311-* cp312-* cp313-*"
|
|
17
|
+
CIBW_SKIP: "*-musllinux*"
|
|
18
|
+
CIBW_MANYLINUX_X86_64_IMAGE: "manylinux_2_28"
|
|
19
|
+
CIBW_TEST_COMMAND: >-
|
|
20
|
+
python -c "import tensorstudio as ts; import tensorstudio._C; x = ts.ones((2, 2), requires_grad=True); y = ((x * 2.0) + 1.0).sum(); y.backward(); assert x.grad.tolist() == [[2.0, 2.0], [2.0, 2.0]]; print(ts.__version__, x.grad.tolist())"
|
|
21
|
+
|
|
22
|
+
jobs:
|
|
23
|
+
windows_wheels:
|
|
24
|
+
name: Windows wheels
|
|
25
|
+
runs-on: windows-latest
|
|
26
|
+
steps:
|
|
27
|
+
- uses: actions/checkout@v4
|
|
28
|
+
- uses: actions/setup-python@v5
|
|
29
|
+
with:
|
|
30
|
+
python-version: "3.12"
|
|
31
|
+
- name: Build Windows wheels
|
|
32
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
33
|
+
env:
|
|
34
|
+
CIBW_ARCHS_WINDOWS: "AMD64"
|
|
35
|
+
- uses: actions/upload-artifact@v4
|
|
36
|
+
with:
|
|
37
|
+
name: dist-windows
|
|
38
|
+
path: wheelhouse/*.whl
|
|
39
|
+
|
|
40
|
+
linux_wheels:
|
|
41
|
+
name: Linux wheels
|
|
42
|
+
runs-on: ubuntu-latest
|
|
43
|
+
needs: windows_wheels
|
|
44
|
+
steps:
|
|
45
|
+
- uses: actions/checkout@v4
|
|
46
|
+
- uses: actions/setup-python@v5
|
|
47
|
+
with:
|
|
48
|
+
python-version: "3.12"
|
|
49
|
+
- name: Build Linux wheels
|
|
50
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
51
|
+
env:
|
|
52
|
+
CIBW_ARCHS_LINUX: "x86_64"
|
|
53
|
+
- uses: actions/upload-artifact@v4
|
|
54
|
+
with:
|
|
55
|
+
name: dist-linux
|
|
56
|
+
path: wheelhouse/*.whl
|
|
57
|
+
|
|
58
|
+
macos_wheels:
|
|
59
|
+
name: macOS wheels
|
|
60
|
+
runs-on: macos-latest
|
|
61
|
+
needs: linux_wheels
|
|
62
|
+
steps:
|
|
63
|
+
- uses: actions/checkout@v4
|
|
64
|
+
- uses: actions/setup-python@v5
|
|
65
|
+
with:
|
|
66
|
+
python-version: "3.12"
|
|
67
|
+
- name: Build macOS wheels
|
|
68
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
69
|
+
env:
|
|
70
|
+
CIBW_ARCHS_MACOS: "auto"
|
|
71
|
+
- uses: actions/upload-artifact@v4
|
|
72
|
+
with:
|
|
73
|
+
name: dist-macos
|
|
74
|
+
path: wheelhouse/*.whl
|
|
75
|
+
|
|
76
|
+
build_sdist:
|
|
77
|
+
name: Build sdist
|
|
78
|
+
runs-on: ubuntu-latest
|
|
79
|
+
needs: macos_wheels
|
|
80
|
+
steps:
|
|
81
|
+
- uses: actions/checkout@v4
|
|
82
|
+
- uses: actions/setup-python@v5
|
|
83
|
+
with:
|
|
84
|
+
python-version: "3.12"
|
|
85
|
+
- name: Build sdist
|
|
86
|
+
run: |
|
|
87
|
+
python -m pip install -U build twine
|
|
88
|
+
python -m build --sdist
|
|
89
|
+
python -m twine check dist/*
|
|
90
|
+
- uses: actions/upload-artifact@v4
|
|
91
|
+
with:
|
|
92
|
+
name: dist-sdist
|
|
93
|
+
path: dist/*.tar.gz
|
|
94
|
+
|
|
95
|
+
publish:
|
|
96
|
+
name: Publish to PyPI
|
|
97
|
+
needs: [windows_wheels, linux_wheels, macos_wheels, build_sdist]
|
|
98
|
+
runs-on: ubuntu-latest
|
|
99
|
+
environment: pypi
|
|
100
|
+
steps:
|
|
101
|
+
- uses: actions/download-artifact@v4
|
|
102
|
+
with:
|
|
103
|
+
pattern: dist-*
|
|
104
|
+
path: dist
|
|
105
|
+
merge-multiple: true
|
|
106
|
+
- name: Publish to PyPI
|
|
107
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
name: Wheels
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- "v*"
|
|
7
|
+
workflow_dispatch:
|
|
8
|
+
|
|
9
|
+
permissions:
|
|
10
|
+
contents: read
|
|
11
|
+
|
|
12
|
+
env:
|
|
13
|
+
CIBW_BUILD: "cp310-* cp311-* cp312-* cp313-*"
|
|
14
|
+
CIBW_SKIP: "*-musllinux*"
|
|
15
|
+
CIBW_MANYLINUX_X86_64_IMAGE: "manylinux_2_28"
|
|
16
|
+
CIBW_TEST_COMMAND: >-
|
|
17
|
+
python -c "import tensorstudio as ts; import tensorstudio._C; x = ts.ones((2, 2), requires_grad=True); y = ((x * 2.0) + 1.0).sum(); y.backward(); assert x.grad.tolist() == [[2.0, 2.0], [2.0, 2.0]]; print(ts.__version__, x.grad.tolist())"
|
|
18
|
+
|
|
19
|
+
jobs:
|
|
20
|
+
windows_wheels:
|
|
21
|
+
name: Windows wheels
|
|
22
|
+
runs-on: windows-latest
|
|
23
|
+
steps:
|
|
24
|
+
- uses: actions/checkout@v4
|
|
25
|
+
- uses: actions/setup-python@v5
|
|
26
|
+
with:
|
|
27
|
+
python-version: "3.12"
|
|
28
|
+
- name: Build Windows wheels
|
|
29
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
30
|
+
env:
|
|
31
|
+
CIBW_ARCHS_WINDOWS: "AMD64"
|
|
32
|
+
- uses: actions/upload-artifact@v4
|
|
33
|
+
with:
|
|
34
|
+
name: wheels-windows
|
|
35
|
+
path: wheelhouse/*.whl
|
|
36
|
+
|
|
37
|
+
linux_wheels:
|
|
38
|
+
name: Linux wheels
|
|
39
|
+
runs-on: ubuntu-latest
|
|
40
|
+
needs: windows_wheels
|
|
41
|
+
steps:
|
|
42
|
+
- uses: actions/checkout@v4
|
|
43
|
+
- uses: actions/setup-python@v5
|
|
44
|
+
with:
|
|
45
|
+
python-version: "3.12"
|
|
46
|
+
- name: Build Linux wheels
|
|
47
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
48
|
+
env:
|
|
49
|
+
CIBW_ARCHS_LINUX: "x86_64"
|
|
50
|
+
- uses: actions/upload-artifact@v4
|
|
51
|
+
with:
|
|
52
|
+
name: wheels-linux
|
|
53
|
+
path: wheelhouse/*.whl
|
|
54
|
+
|
|
55
|
+
macos_wheels:
|
|
56
|
+
name: macOS wheels
|
|
57
|
+
runs-on: macos-latest
|
|
58
|
+
needs: linux_wheels
|
|
59
|
+
steps:
|
|
60
|
+
- uses: actions/checkout@v4
|
|
61
|
+
- uses: actions/setup-python@v5
|
|
62
|
+
with:
|
|
63
|
+
python-version: "3.12"
|
|
64
|
+
- name: Build macOS wheels
|
|
65
|
+
uses: pypa/cibuildwheel@v2.23.3
|
|
66
|
+
env:
|
|
67
|
+
CIBW_ARCHS_MACOS: "auto"
|
|
68
|
+
- uses: actions/upload-artifact@v4
|
|
69
|
+
with:
|
|
70
|
+
name: wheels-macos
|
|
71
|
+
path: wheelhouse/*.whl
|
|
72
|
+
|
|
73
|
+
build_sdist:
|
|
74
|
+
name: Build sdist
|
|
75
|
+
runs-on: ubuntu-latest
|
|
76
|
+
needs: macos_wheels
|
|
77
|
+
steps:
|
|
78
|
+
- uses: actions/checkout@v4
|
|
79
|
+
- uses: actions/setup-python@v5
|
|
80
|
+
with:
|
|
81
|
+
python-version: "3.12"
|
|
82
|
+
- name: Build sdist
|
|
83
|
+
run: |
|
|
84
|
+
python -m pip install -U build twine
|
|
85
|
+
python -m build --sdist
|
|
86
|
+
python -m twine check dist/*
|
|
87
|
+
- uses: actions/upload-artifact@v4
|
|
88
|
+
with:
|
|
89
|
+
name: sdist
|
|
90
|
+
path: dist/*.tar.gz
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 1.0.0rc2
|
|
4
|
+
|
|
5
|
+
- Added `*_like` tensor creation helpers for zero, one, full, empty, uniform
|
|
6
|
+
random, and normal random tensors.
|
|
7
|
+
- Added `nn.Identity`, `nn.LeakyReLU`, `nn.Softplus`,
|
|
8
|
+
`nn.BCEWithLogitsLoss`, `nn.HuberLoss`, and matching functional helpers.
|
|
9
|
+
- Expanded `nn.Module` with child/module introspection, trainable parameter
|
|
10
|
+
filtering, freeze/unfreeze helpers, parameter counting, recursive `apply`,
|
|
11
|
+
and richer `repr` details.
|
|
12
|
+
- Added optimizer utilities for gradient clipping and lightweight
|
|
13
|
+
`StepLR`/`ExponentialLR` learning-rate schedulers.
|
|
14
|
+
- Added `len(DataLoader)` batch counting with `drop_last` support.
|
|
15
|
+
- Added typed C++ fast paths for contiguous elementwise/unary kernels and a
|
|
16
|
+
contiguous matmul kernel that avoids per-element Tensor method dispatch.
|
|
17
|
+
- Bumped the next release candidate after public `1.0.0rc1` artifacts.
|
|
18
|
+
|
|
19
|
+
## 1.0.0rc1
|
|
20
|
+
|
|
21
|
+
- Release-candidate hardening toward a CPU-only v1.0.0 API foundation.
|
|
22
|
+
- Added additional tensor creation helpers, math operations, comparisons,
|
|
23
|
+
no-grad mode, state APIs, data utilities, and Windows-first CI/release docs.
|
|
24
|
+
- This is not final v1.0.0; remaining platform checklist items must pass before
|
|
25
|
+
a stable release.
|
|
26
|
+
|
|
27
|
+
## 0.1.1
|
|
28
|
+
|
|
29
|
+
- Publishable wheel release for CPython 3.10-3.13.
|
|
30
|
+
- Fixed MSVC build portability by removing non-portable `ssize_t` usage.
|
|
31
|
+
- Updated wheel CI to build 64-bit Windows wheels and modern Linux wheels.
|
|
32
|
+
- Expanded documentation with MkDocs navigation and detailed usage guides.
|
|
33
|
+
|
|
34
|
+
## 0.1.0
|
|
35
|
+
|
|
36
|
+
- Initial experimental release.
|
|
37
|
+
- C++20 CPU tensor core with Python bindings.
|
|
38
|
+
- Basic broadcasting, matrix multiplication, reductions, activations, and views.
|
|
39
|
+
- Reverse-mode autograd for the initial operation set.
|
|
40
|
+
- Python `nn`, `optim`, serialization, examples, tests, docs, and CI workflows.
|