tensorstudio 1.8.0__tar.gz → 1.9.0__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.8.0 → tensorstudio-1.9.0}/CHANGELOG.md +17 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/CMakeLists.txt +70 -70
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/PKG-INFO +37 -17
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/README.md +36 -16
- tensorstudio-1.9.0/benchmarks/results.md +347 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/results_matmul.md +13 -13
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/autograd/coverage.md +1 -1
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/core/api-reference.md +26 -5
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/core/tensors.md +2 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/hardware/cpu-backend.md +1 -1
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/index.md +3 -2
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/interchange/onnx.md +1 -1
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/interchange/serialization.md +1 -1
- tensorstudio-1.9.0/docs/nn/initializers.md +70 -0
- tensorstudio-1.9.0/docs/nn/losses-and-summary.md +79 -0
- tensorstudio-1.9.0/docs/nn/modules.md +213 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/nn/overview.md +42 -3
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/nn/training.md +1 -1
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/release/publishing.md +4 -4
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/release/versioning.md +2 -2
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/roadmap/milestones.md +4 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/roadmap/roadmap.md +15 -9
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/ops.hpp +16 -1
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/version.hpp +7 -7
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/mkdocs.yml +2 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/pyproject.toml +95 -95
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/_C.pyi +16 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/__init__.py +4 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/_version.py +5 -5
- tensorstudio-1.9.0/python/tensorstudio/nn/__init__.py +170 -0
- tensorstudio-1.9.0/python/tensorstudio/nn/functional.py +500 -0
- tensorstudio-1.9.0/python/tensorstudio/nn/init.py +118 -0
- tensorstudio-1.9.0/python/tensorstudio/nn/losses.py +169 -0
- tensorstudio-1.9.0/python/tensorstudio/nn/modules.py +999 -0
- tensorstudio-1.9.0/python/tensorstudio/nn/summary.py +109 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/ops.py +42 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/bindings/bind_ops.cpp +50 -3
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/ops.cpp +502 -26
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_import.py +13 -13
- tensorstudio-1.9.0/tests/test_nn_building_blocks.py +205 -0
- tensorstudio-1.8.0/benchmarks/results.md +0 -347
- tensorstudio-1.8.0/docs/nn/modules.md +0 -141
- tensorstudio-1.8.0/python/tensorstudio/nn/__init__.py +0 -82
- tensorstudio-1.8.0/python/tensorstudio/nn/functional.py +0 -166
- tensorstudio-1.8.0/python/tensorstudio/nn/losses.py +0 -73
- tensorstudio-1.8.0/python/tensorstudio/nn/modules.py +0 -511
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/.gitattributes +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/.github/workflows/ci.yml +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/.github/workflows/publish-testpypi.yml +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/.github/workflows/publish.yml +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/.github/workflows/wheels.yml +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/.gitignore +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/.pre-commit-config.yaml +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/CONTRIBUTING.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/LICENSE +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/SECURITY.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmark_all.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/__init__.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_activations.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_autograd.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_conv2d.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_elementwise.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_matmul.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_pooling.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_reductions.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_tensor_ops.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/bench_training_loop.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/benchmark_report.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/results_conv2d.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/results_pooling.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/results_reductions.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/results_tensor_ops.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/benchmarks/thresholds.json +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/autograd/gradient-notes.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/autograd/overview.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/core/broadcasting.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/core/math-and-statistics.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/core/native-cpp-core.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/data/dataloader-patterns.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/data/datasets-and-dataloaders.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/data/tensor-datasets.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/development/contributing.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/development/cpp-first.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/getting-started/installation.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/getting-started/quickstart.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/getting-started/source-build.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/hardware/linux.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/hardware/macos.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/hardware/windows.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/interchange/model-formats.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/interchange/numpy-interop.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/interchange/trusted-serialization.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/nn/optimizers.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/performance/benchmarks.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/performance/optimization.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/performance/profiling.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/project/checkpoints.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/project/project-layout.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/project/workflows.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/release/checklist.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/roadmap/priorities.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/vision/dataset-creation.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/docs/vision/overview.md +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/basic_tensor_ops.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/export_onnx.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/image_folder_classification.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/linear_regression.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/project_training.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/save_load_model.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/tiny_mlp.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/examples/vision_classifier.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/autograd.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/device.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/dtype.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/errors.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/module.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/optim.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/perf.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/random.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/serialization.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/shape.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/storage.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/include/tensorstudio/tensor.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/autograd.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/data/__init__.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/data/dataloader.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/data/dataset.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/dtypes.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/errors.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/grad_mode.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/interchange/__init__.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/interchange/onnx.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/math.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/optim/__init__.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/optim/adam.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/optim/adamw.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/optim/lr_scheduler.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/optim/sgd.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/optim/utils.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/performance.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/project/__init__.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/project/checkpoint.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/project/config.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/project/trainer.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/py.typed +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/serialization.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/tensor.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/typing.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/vision/__init__.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/vision/datasets.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/vision/io.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/vision/metrics.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/vision/models.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/vision/transforms.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/python/tensorstudio/vision/visualization.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/bindings/bind_autograd.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/bindings/bind_nn.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/bindings/bind_optim.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/bindings/bind_tensor.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/bindings/bindings.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/bindings/bindings.hpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/autograd.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/device.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/dtype.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/errors.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/module.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/optim.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/perf.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/random.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/serialization.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/shape.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/storage.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/src/core/tensor.cpp +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/test_all.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_autograd.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_autograd_hardening.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_benchmark_report.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_broadcasting.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_core_math_expansion.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_data.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_errors.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_indexing.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_interchange.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_nn.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_numpy_interop.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_ops.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_optim.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_performance.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_project.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_serialization.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_tensor.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_views.py +0 -0
- {tensorstudio-1.8.0 → tensorstudio-1.9.0}/tests/test_vision.py +0 -0
|
@@ -2,6 +2,23 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## 1.9.0 - 2026-07-07
|
|
6
|
+
|
|
7
|
+
- Completed the ordered Neural Network Building Blocks roadmap section as one
|
|
8
|
+
release batch.
|
|
9
|
+
- Added native grouped `conv2d`, native `conv_transpose2d`, and native
|
|
10
|
+
embedding lookup with autograd support.
|
|
11
|
+
- Added Python-level `Conv1d`, `DepthwiseConv2d`, `ConvTranspose2d`,
|
|
12
|
+
`BatchNorm1d`, `BatchNorm2d`, `LayerNorm`, `Embedding`,
|
|
13
|
+
adaptive/global pooling, and additional activation modules.
|
|
14
|
+
- Added `tensorstudio.nn.init` with Xavier, Kaiming, normal, uniform, zero, and
|
|
15
|
+
one initializers.
|
|
16
|
+
- Added label-smoothing cross entropy, focal loss, KL divergence, negative log
|
|
17
|
+
likelihood, and cosine embedding loss modules and functional helpers.
|
|
18
|
+
- Added module buffers, buffer-aware `state_dict()` support, and model summary
|
|
19
|
+
utilities for parameters, shapes, and estimated tensor memory.
|
|
20
|
+
- Expanded tests and docs for the section-5 neural-network API surface.
|
|
21
|
+
|
|
5
22
|
## 1.8.0 - 2026-07-07
|
|
6
23
|
|
|
7
24
|
- Completed the ordered Autograd Coverage And Hardening roadmap section as one
|
|
@@ -1,70 +1,70 @@
|
|
|
1
|
-
cmake_minimum_required(VERSION 3.18)
|
|
2
|
-
|
|
3
|
-
project(tensorstudio VERSION 1.
|
|
4
|
-
|
|
5
|
-
find_package(Python COMPONENTS Interpreter Development.Module REQUIRED)
|
|
6
|
-
set(PYBIND11_FINDPYTHON ON)
|
|
7
|
-
find_package(pybind11 CONFIG REQUIRED)
|
|
8
|
-
|
|
9
|
-
option(TENSORSTUDIO_ENABLE_BLAS "Enable optional CBLAS-backed matmul when available" ON)
|
|
10
|
-
|
|
11
|
-
set(TENSORSTUDIO_CORE_SOURCES
|
|
12
|
-
src/core/tensor.cpp
|
|
13
|
-
src/core/dtype.cpp
|
|
14
|
-
src/core/shape.cpp
|
|
15
|
-
src/core/device.cpp
|
|
16
|
-
src/core/storage.cpp
|
|
17
|
-
src/core/ops.cpp
|
|
18
|
-
src/core/autograd.cpp
|
|
19
|
-
src/core/module.cpp
|
|
20
|
-
src/core/optim.cpp
|
|
21
|
-
src/core/random.cpp
|
|
22
|
-
src/core/serialization.cpp
|
|
23
|
-
src/core/errors.cpp
|
|
24
|
-
src/core/perf.cpp
|
|
25
|
-
)
|
|
26
|
-
|
|
27
|
-
set(TENSORSTUDIO_BINDING_SOURCES
|
|
28
|
-
src/bindings/bindings.cpp
|
|
29
|
-
src/bindings/bind_tensor.cpp
|
|
30
|
-
src/bindings/bind_ops.cpp
|
|
31
|
-
src/bindings/bind_autograd.cpp
|
|
32
|
-
src/bindings/bind_nn.cpp
|
|
33
|
-
src/bindings/bind_optim.cpp
|
|
34
|
-
)
|
|
35
|
-
|
|
36
|
-
pybind11_add_module(_C MODULE
|
|
37
|
-
${TENSORSTUDIO_CORE_SOURCES}
|
|
38
|
-
${TENSORSTUDIO_BINDING_SOURCES}
|
|
39
|
-
)
|
|
40
|
-
|
|
41
|
-
target_include_directories(_C PRIVATE include src/bindings)
|
|
42
|
-
target_compile_features(_C PRIVATE cxx_std_20)
|
|
43
|
-
|
|
44
|
-
if(TENSORSTUDIO_ENABLE_BLAS)
|
|
45
|
-
find_package(BLAS)
|
|
46
|
-
if(BLAS_FOUND)
|
|
47
|
-
include(CheckIncludeFileCXX)
|
|
48
|
-
check_include_file_cxx(cblas.h TENSORSTUDIO_HAVE_CBLAS_H)
|
|
49
|
-
target_link_libraries(_C PRIVATE ${BLAS_LIBRARIES})
|
|
50
|
-
if(APPLE)
|
|
51
|
-
target_compile_definitions(_C PRIVATE TENSORSTUDIO_HAS_ACCELERATE=1)
|
|
52
|
-
elseif(TENSORSTUDIO_HAVE_CBLAS_H)
|
|
53
|
-
target_compile_definitions(_C PRIVATE TENSORSTUDIO_HAS_CBLAS=1)
|
|
54
|
-
endif()
|
|
55
|
-
endif()
|
|
56
|
-
endif()
|
|
57
|
-
|
|
58
|
-
if(MSVC)
|
|
59
|
-
target_compile_options(_C PRIVATE /W4 /permissive-)
|
|
60
|
-
else()
|
|
61
|
-
target_compile_options(_C PRIVATE -Wall -Wextra -Wpedantic)
|
|
62
|
-
endif()
|
|
63
|
-
|
|
64
|
-
target_compile_definitions(_C PRIVATE TENSORSTUDIO_VERSION="${PROJECT_VERSION}")
|
|
65
|
-
|
|
66
|
-
install(TARGETS _C
|
|
67
|
-
LIBRARY DESTINATION tensorstudio
|
|
68
|
-
RUNTIME DESTINATION tensorstudio
|
|
69
|
-
ARCHIVE DESTINATION tensorstudio
|
|
70
|
-
)
|
|
1
|
+
cmake_minimum_required(VERSION 3.18)
|
|
2
|
+
|
|
3
|
+
project(tensorstudio VERSION 1.9.0 LANGUAGES CXX)
|
|
4
|
+
|
|
5
|
+
find_package(Python COMPONENTS Interpreter Development.Module REQUIRED)
|
|
6
|
+
set(PYBIND11_FINDPYTHON ON)
|
|
7
|
+
find_package(pybind11 CONFIG REQUIRED)
|
|
8
|
+
|
|
9
|
+
option(TENSORSTUDIO_ENABLE_BLAS "Enable optional CBLAS-backed matmul when available" ON)
|
|
10
|
+
|
|
11
|
+
set(TENSORSTUDIO_CORE_SOURCES
|
|
12
|
+
src/core/tensor.cpp
|
|
13
|
+
src/core/dtype.cpp
|
|
14
|
+
src/core/shape.cpp
|
|
15
|
+
src/core/device.cpp
|
|
16
|
+
src/core/storage.cpp
|
|
17
|
+
src/core/ops.cpp
|
|
18
|
+
src/core/autograd.cpp
|
|
19
|
+
src/core/module.cpp
|
|
20
|
+
src/core/optim.cpp
|
|
21
|
+
src/core/random.cpp
|
|
22
|
+
src/core/serialization.cpp
|
|
23
|
+
src/core/errors.cpp
|
|
24
|
+
src/core/perf.cpp
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
set(TENSORSTUDIO_BINDING_SOURCES
|
|
28
|
+
src/bindings/bindings.cpp
|
|
29
|
+
src/bindings/bind_tensor.cpp
|
|
30
|
+
src/bindings/bind_ops.cpp
|
|
31
|
+
src/bindings/bind_autograd.cpp
|
|
32
|
+
src/bindings/bind_nn.cpp
|
|
33
|
+
src/bindings/bind_optim.cpp
|
|
34
|
+
)
|
|
35
|
+
|
|
36
|
+
pybind11_add_module(_C MODULE
|
|
37
|
+
${TENSORSTUDIO_CORE_SOURCES}
|
|
38
|
+
${TENSORSTUDIO_BINDING_SOURCES}
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
target_include_directories(_C PRIVATE include src/bindings)
|
|
42
|
+
target_compile_features(_C PRIVATE cxx_std_20)
|
|
43
|
+
|
|
44
|
+
if(TENSORSTUDIO_ENABLE_BLAS)
|
|
45
|
+
find_package(BLAS)
|
|
46
|
+
if(BLAS_FOUND)
|
|
47
|
+
include(CheckIncludeFileCXX)
|
|
48
|
+
check_include_file_cxx(cblas.h TENSORSTUDIO_HAVE_CBLAS_H)
|
|
49
|
+
target_link_libraries(_C PRIVATE ${BLAS_LIBRARIES})
|
|
50
|
+
if(APPLE)
|
|
51
|
+
target_compile_definitions(_C PRIVATE TENSORSTUDIO_HAS_ACCELERATE=1)
|
|
52
|
+
elseif(TENSORSTUDIO_HAVE_CBLAS_H)
|
|
53
|
+
target_compile_definitions(_C PRIVATE TENSORSTUDIO_HAS_CBLAS=1)
|
|
54
|
+
endif()
|
|
55
|
+
endif()
|
|
56
|
+
endif()
|
|
57
|
+
|
|
58
|
+
if(MSVC)
|
|
59
|
+
target_compile_options(_C PRIVATE /W4 /permissive-)
|
|
60
|
+
else()
|
|
61
|
+
target_compile_options(_C PRIVATE -Wall -Wextra -Wpedantic)
|
|
62
|
+
endif()
|
|
63
|
+
|
|
64
|
+
target_compile_definitions(_C PRIVATE TENSORSTUDIO_VERSION="${PROJECT_VERSION}")
|
|
65
|
+
|
|
66
|
+
install(TARGETS _C
|
|
67
|
+
LIBRARY DESTINATION tensorstudio
|
|
68
|
+
RUNTIME DESTINATION tensorstudio
|
|
69
|
+
ARCHIVE DESTINATION tensorstudio
|
|
70
|
+
)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.2
|
|
2
2
|
Name: tensorstudio
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.9.0
|
|
4
4
|
Summary: TensorStudio is a compact C++ tensor and autograd engine with a Python API for learning, experimentation, and lightweight ML workloads.
|
|
5
5
|
Keywords: tensor,autograd,machine-learning,cpp,pybind11
|
|
6
6
|
Author: TensorStudio contributors
|
|
@@ -71,13 +71,15 @@ Description-Content-Type: text/markdown
|
|
|
71
71
|
TensorStudio is a compact C++ tensor and autograd engine with a Python API for
|
|
72
72
|
learning, experimentation, and lightweight ML workloads.
|
|
73
73
|
|
|
74
|
-
TensorStudio `1.
|
|
74
|
+
TensorStudio `1.9.0` is a CPU-only stable API foundation with native C++
|
|
75
75
|
threading, storage reuse, SIMD-friendly typed kernels, and optional
|
|
76
76
|
CBLAS/Accelerate matrix multiplication when available. It adds native stable
|
|
77
77
|
softmax/logsumexp, batched matrix multiplication, statistical reductions,
|
|
78
78
|
boolean reductions, seeded random distributions, and a hardened eager autograd
|
|
79
|
-
lifecycle.
|
|
80
|
-
|
|
79
|
+
lifecycle. The neural-network layer now includes grouped/depthwise/1D/
|
|
80
|
+
transposed convolution, normalization layers, embeddings, richer activations,
|
|
81
|
+
initializers, additional losses, and model summaries. It is eager-only,
|
|
82
|
+
intentionally compact, and not a replacement for mature ML frameworks.
|
|
81
83
|
|
|
82
84
|
## Install
|
|
83
85
|
|
|
@@ -287,6 +289,23 @@ print(model.state_dict().keys())
|
|
|
287
289
|
print(model.parameter_count())
|
|
288
290
|
```
|
|
289
291
|
|
|
292
|
+
The `1.9.0` neural-network surface also includes initialization helpers,
|
|
293
|
+
normalization layers, embeddings, grouped/depthwise/1D/transposed convolution,
|
|
294
|
+
adaptive/global pooling, richer activations, and model summaries:
|
|
295
|
+
|
|
296
|
+
```python
|
|
297
|
+
model = nn.Sequential(
|
|
298
|
+
nn.Conv2d(1, 8, kernel_size=3, padding=1),
|
|
299
|
+
nn.BatchNorm2d(8),
|
|
300
|
+
nn.GELU(),
|
|
301
|
+
nn.GlobalAvgPool2d(),
|
|
302
|
+
nn.Flatten(),
|
|
303
|
+
nn.Linear(8, 10),
|
|
304
|
+
)
|
|
305
|
+
nn.init.kaiming_uniform_(model[0].weight, nonlinearity="relu", seed=7)
|
|
306
|
+
print(nn.summary(model, input_shape=(1, 1, 28, 28))["total_parameters"])
|
|
307
|
+
```
|
|
308
|
+
|
|
290
309
|
## Vision
|
|
291
310
|
|
|
292
311
|
TensorStudio includes a practical computer-vision namespace for local image
|
|
@@ -391,11 +410,11 @@ Run the loose local regression thresholds with:
|
|
|
391
410
|
python benchmark_all.py --check-thresholds
|
|
392
411
|
```
|
|
393
412
|
|
|
394
|
-
On one Windows CPython 3.10 development run reporting `1.
|
|
413
|
+
On one Windows CPython 3.10 development run reporting `1.9.0`, with
|
|
395
414
|
TensorStudio threads enabled, storage pooling enabled, SSE2 autovectorization
|
|
396
415
|
reported, and no BLAS provider found, TensorStudio beat NumPy on 7 local
|
|
397
416
|
benchmark cases and lost on 96 NumPy-comparable cases. JAX CPU dispatch was
|
|
398
|
-
available on that machine; TensorStudio won
|
|
417
|
+
available on that machine; TensorStudio won 55 local cases and lost 43. The
|
|
399
418
|
strongest local wins were the simple NumPy convolution/pooling reference loops
|
|
400
419
|
and some small JAX-dispatch-heavy eager cases. NumPy and JAX were faster for
|
|
401
420
|
many elementwise, reduction, matrix multiplication, larger activation, and
|
|
@@ -407,15 +426,15 @@ Snapshot from that local run:
|
|
|
407
426
|
|
|
408
427
|
| operation | shape | TensorStudio | NumPy | JAX CPU dispatch | TS vs NumPy | TS vs JAX |
|
|
409
428
|
|---|---:|---:|---:|---:|---:|---:|
|
|
410
|
-
| `sigmoid` | `(32,)` | 0.
|
|
411
|
-
| `mean` | `(32,)` | 0.
|
|
412
|
-
| `sum_axis1` | `(16, 16)` | 0.
|
|
413
|
-
| `chain_relu` | `(128,)` | 0.
|
|
414
|
-
| `matmul` | `(256, 256)` | 2.
|
|
415
|
-
| `conv2d_3x3_padding1` | `(1, 1, 8, 8)` | 0.
|
|
416
|
-
| `max_pool2d_2x2` | `(1, 1, 16, 16)` | 0.
|
|
417
|
-
| `avg_pool2d_2x2` | `(1, 1, 16, 16)` | 0.
|
|
418
|
-
| `elementwise_backward` | `(1024,)` | 2.
|
|
429
|
+
| `sigmoid` | `(32,)` | 0.0154 ms | 0.0048 ms | 0.0855 ms | 0.3098x | 5.5404x |
|
|
430
|
+
| `mean` | `(32,)` | 0.0187 ms | 0.0104 ms | 0.0143 ms | 0.5575x | 0.7616x |
|
|
431
|
+
| `sum_axis1` | `(16, 16)` | 0.0172 ms | 0.0027 ms | 0.0136 ms | 0.1551x | 0.7942x |
|
|
432
|
+
| `chain_relu` | `(128,)` | 0.0957 ms | 0.0057 ms | 0.1030 ms | 0.0596x | 1.0768x |
|
|
433
|
+
| `matmul` | `(256, 256)` | 2.3777 ms | 0.4328 ms | 0.2489 ms | 0.1820x | 0.1047x |
|
|
434
|
+
| `conv2d_3x3_padding1` | `(1, 1, 8, 8)` | 0.2216 ms | 1.3908 ms | 0.1073 ms | 6.2770x | 0.4841x |
|
|
435
|
+
| `max_pool2d_2x2` | `(1, 1, 16, 16)` | 0.0280 ms | 0.1846 ms | n/a | 6.5816x | n/a |
|
|
436
|
+
| `avg_pool2d_2x2` | `(1, 1, 16, 16)` | 0.0281 ms | 0.5595 ms | n/a | 19.8874x | n/a |
|
|
437
|
+
| `elementwise_backward` | `(1024,)` | 2.8255 ms | n/a | n/a | n/a | n/a |
|
|
419
438
|
|
|
420
439
|
Speedup is `competitor median / TensorStudio median`, so values above `1.0x`
|
|
421
440
|
favor TensorStudio.
|
|
@@ -516,8 +535,9 @@ tokens or print secrets.
|
|
|
516
535
|
exposing a compatible CBLAS/Accelerate interface; otherwise TensorStudio uses
|
|
517
536
|
a portable C++ fallback.
|
|
518
537
|
- No graph compiler or distributed runtime.
|
|
519
|
-
- Convolution and pooling support are
|
|
520
|
-
`conv2d`, `
|
|
538
|
+
- Convolution and pooling support are CPU-only. Native kernels include NCHW
|
|
539
|
+
`conv2d`, grouped/depthwise convolution, `conv_transpose2d`, `max_pool2d`,
|
|
540
|
+
`avg_pool2d`, and embedding lookup; they are not CUDA/cuDNN replacements.
|
|
521
541
|
- Vision covers local image-classification utilities, metrics, visualization,
|
|
522
542
|
and compact CNNs. It is not an OpenCV replacement and does not include
|
|
523
543
|
pretrained model zoos, detection/segmentation training stacks, video IO, or
|
|
@@ -7,13 +7,15 @@
|
|
|
7
7
|
TensorStudio is a compact C++ tensor and autograd engine with a Python API for
|
|
8
8
|
learning, experimentation, and lightweight ML workloads.
|
|
9
9
|
|
|
10
|
-
TensorStudio `1.
|
|
10
|
+
TensorStudio `1.9.0` is a CPU-only stable API foundation with native C++
|
|
11
11
|
threading, storage reuse, SIMD-friendly typed kernels, and optional
|
|
12
12
|
CBLAS/Accelerate matrix multiplication when available. It adds native stable
|
|
13
13
|
softmax/logsumexp, batched matrix multiplication, statistical reductions,
|
|
14
14
|
boolean reductions, seeded random distributions, and a hardened eager autograd
|
|
15
|
-
lifecycle.
|
|
16
|
-
|
|
15
|
+
lifecycle. The neural-network layer now includes grouped/depthwise/1D/
|
|
16
|
+
transposed convolution, normalization layers, embeddings, richer activations,
|
|
17
|
+
initializers, additional losses, and model summaries. It is eager-only,
|
|
18
|
+
intentionally compact, and not a replacement for mature ML frameworks.
|
|
17
19
|
|
|
18
20
|
## Install
|
|
19
21
|
|
|
@@ -223,6 +225,23 @@ print(model.state_dict().keys())
|
|
|
223
225
|
print(model.parameter_count())
|
|
224
226
|
```
|
|
225
227
|
|
|
228
|
+
The `1.9.0` neural-network surface also includes initialization helpers,
|
|
229
|
+
normalization layers, embeddings, grouped/depthwise/1D/transposed convolution,
|
|
230
|
+
adaptive/global pooling, richer activations, and model summaries:
|
|
231
|
+
|
|
232
|
+
```python
|
|
233
|
+
model = nn.Sequential(
|
|
234
|
+
nn.Conv2d(1, 8, kernel_size=3, padding=1),
|
|
235
|
+
nn.BatchNorm2d(8),
|
|
236
|
+
nn.GELU(),
|
|
237
|
+
nn.GlobalAvgPool2d(),
|
|
238
|
+
nn.Flatten(),
|
|
239
|
+
nn.Linear(8, 10),
|
|
240
|
+
)
|
|
241
|
+
nn.init.kaiming_uniform_(model[0].weight, nonlinearity="relu", seed=7)
|
|
242
|
+
print(nn.summary(model, input_shape=(1, 1, 28, 28))["total_parameters"])
|
|
243
|
+
```
|
|
244
|
+
|
|
226
245
|
## Vision
|
|
227
246
|
|
|
228
247
|
TensorStudio includes a practical computer-vision namespace for local image
|
|
@@ -327,11 +346,11 @@ Run the loose local regression thresholds with:
|
|
|
327
346
|
python benchmark_all.py --check-thresholds
|
|
328
347
|
```
|
|
329
348
|
|
|
330
|
-
On one Windows CPython 3.10 development run reporting `1.
|
|
349
|
+
On one Windows CPython 3.10 development run reporting `1.9.0`, with
|
|
331
350
|
TensorStudio threads enabled, storage pooling enabled, SSE2 autovectorization
|
|
332
351
|
reported, and no BLAS provider found, TensorStudio beat NumPy on 7 local
|
|
333
352
|
benchmark cases and lost on 96 NumPy-comparable cases. JAX CPU dispatch was
|
|
334
|
-
available on that machine; TensorStudio won
|
|
353
|
+
available on that machine; TensorStudio won 55 local cases and lost 43. The
|
|
335
354
|
strongest local wins were the simple NumPy convolution/pooling reference loops
|
|
336
355
|
and some small JAX-dispatch-heavy eager cases. NumPy and JAX were faster for
|
|
337
356
|
many elementwise, reduction, matrix multiplication, larger activation, and
|
|
@@ -343,15 +362,15 @@ Snapshot from that local run:
|
|
|
343
362
|
|
|
344
363
|
| operation | shape | TensorStudio | NumPy | JAX CPU dispatch | TS vs NumPy | TS vs JAX |
|
|
345
364
|
|---|---:|---:|---:|---:|---:|---:|
|
|
346
|
-
| `sigmoid` | `(32,)` | 0.
|
|
347
|
-
| `mean` | `(32,)` | 0.
|
|
348
|
-
| `sum_axis1` | `(16, 16)` | 0.
|
|
349
|
-
| `chain_relu` | `(128,)` | 0.
|
|
350
|
-
| `matmul` | `(256, 256)` | 2.
|
|
351
|
-
| `conv2d_3x3_padding1` | `(1, 1, 8, 8)` | 0.
|
|
352
|
-
| `max_pool2d_2x2` | `(1, 1, 16, 16)` | 0.
|
|
353
|
-
| `avg_pool2d_2x2` | `(1, 1, 16, 16)` | 0.
|
|
354
|
-
| `elementwise_backward` | `(1024,)` | 2.
|
|
365
|
+
| `sigmoid` | `(32,)` | 0.0154 ms | 0.0048 ms | 0.0855 ms | 0.3098x | 5.5404x |
|
|
366
|
+
| `mean` | `(32,)` | 0.0187 ms | 0.0104 ms | 0.0143 ms | 0.5575x | 0.7616x |
|
|
367
|
+
| `sum_axis1` | `(16, 16)` | 0.0172 ms | 0.0027 ms | 0.0136 ms | 0.1551x | 0.7942x |
|
|
368
|
+
| `chain_relu` | `(128,)` | 0.0957 ms | 0.0057 ms | 0.1030 ms | 0.0596x | 1.0768x |
|
|
369
|
+
| `matmul` | `(256, 256)` | 2.3777 ms | 0.4328 ms | 0.2489 ms | 0.1820x | 0.1047x |
|
|
370
|
+
| `conv2d_3x3_padding1` | `(1, 1, 8, 8)` | 0.2216 ms | 1.3908 ms | 0.1073 ms | 6.2770x | 0.4841x |
|
|
371
|
+
| `max_pool2d_2x2` | `(1, 1, 16, 16)` | 0.0280 ms | 0.1846 ms | n/a | 6.5816x | n/a |
|
|
372
|
+
| `avg_pool2d_2x2` | `(1, 1, 16, 16)` | 0.0281 ms | 0.5595 ms | n/a | 19.8874x | n/a |
|
|
373
|
+
| `elementwise_backward` | `(1024,)` | 2.8255 ms | n/a | n/a | n/a | n/a |
|
|
355
374
|
|
|
356
375
|
Speedup is `competitor median / TensorStudio median`, so values above `1.0x`
|
|
357
376
|
favor TensorStudio.
|
|
@@ -452,8 +471,9 @@ tokens or print secrets.
|
|
|
452
471
|
exposing a compatible CBLAS/Accelerate interface; otherwise TensorStudio uses
|
|
453
472
|
a portable C++ fallback.
|
|
454
473
|
- No graph compiler or distributed runtime.
|
|
455
|
-
- Convolution and pooling support are
|
|
456
|
-
`conv2d`, `
|
|
474
|
+
- Convolution and pooling support are CPU-only. Native kernels include NCHW
|
|
475
|
+
`conv2d`, grouped/depthwise convolution, `conv_transpose2d`, `max_pool2d`,
|
|
476
|
+
`avg_pool2d`, and embedding lookup; they are not CUDA/cuDNN replacements.
|
|
457
477
|
- Vision covers local image-classification utilities, metrics, visualization,
|
|
458
478
|
and compact CNNs. It is not an OpenCV replacement and does not include
|
|
459
479
|
pretrained model zoos, detection/segmentation training stacks, video IO, or
|