tensoracle 2.1.1__tar.gz → 2.1.2__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.
- {tensoracle-2.1.1 → tensoracle-2.1.2}/CMakeLists.txt +8 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/PKG-INFO +2 -2
- {tensoracle-2.1.1 → tensoracle-2.1.2}/README.md +1 -1
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/tensoracle.h +1 -1
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/cpp-python-repositories.md +1 -1
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/index.md +1 -1
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/migration.md +1 -1
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/tensorrt-sdk.md +2 -2
- {tensoracle-2.1.1 → tensoracle-2.1.2}/src/tensoracle/_version.py +2 -2
- tensoracle-2.1.2/src/tensoracle/py.typed +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_distribution.py +59 -4
- {tensoracle-2.1.1 → tensoracle-2.1.2}/.gitignore +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/LICENSE +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/bindings.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/build_backend.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/CMakeLists.txt +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/cmake/TensoracleCubinPlugin.cmake +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/cmake/TensoracleCuda.cmake +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/cmake/TensoracleDependencies.cmake +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/cmake/TensoracleJson.cmake +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/cmake/tensoracleConfig.cmake.in +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/builder.h +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/builder.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/cache.h +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/cache.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/cubin.h +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/cubin.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/cubin_plugin.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/engine.h +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/engine.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/plugins.h +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/plugins.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/include/tensoracle/tensoracle.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/abi.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/builder.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/builder_internal.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/bundle.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/bundle_internal.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/cache.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/cache.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/cache_management.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/cache_management_internal.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/cache_management_internal.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/cache_open.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/comparison.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/cubin_plugin.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/engine.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/engine_internal.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/error.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/error.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/native_exports.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/plugins.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/producer.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/safetensors.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/safetensors.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/sha256.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/structure.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/src/tensoracle.map +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/CMakeLists.txt +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/abi.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/builder.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/builder_fixture.hpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/builder_probe.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/c_consumer.c +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/cache.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/cache_management.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/cache_probe.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/comparison.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/consumer/CMakeLists.txt +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/consumer/main.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/core.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/cubin.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/driver_failures.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/execution.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/installed.cmake +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/native_exports.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/native_exports_fixture.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/plugin_fixture.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/plugins.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/precision.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/utilities.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cpp/tests/weights.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/cubin_bindings.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/api/bundle.md +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/api/index.md +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/api/producer.md +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/optimization.md +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/docs/precision.md +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/CMakeLists.txt +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/README.md +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bindings.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/bundle.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/bundle.json +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm120/bias.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm120/dot.specialized.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm120/dot.tf32-control.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm120/dot.unspecialized.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm120/scale.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm86/bias.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm86/dot.specialized.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm86/dot.tf32-control.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm86/dot.unspecialized.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm86/scale.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm89/bias.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm89/dot.specialized.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm89/dot.tf32-control.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm89/dot.unspecialized.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm89/scale.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/example_cubin_plugin/__init__.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/example_cubin_plugin/weights.safetensors +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/kernels.cu +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/kernels.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/plugin.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/pyproject.toml +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/wheel_consumer/CMakeLists.txt +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/wheel_consumer/README.md +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/wheel_consumer/bindings.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/wheel_consumer/pyproject.toml +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/examples/wheel_consumer/src/tensoracle_consumer/__init__.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/mkdocs.yml +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/pyproject.toml +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/src/tensoracle/__init__.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/src/tensoracle/_cli.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/src/tensoracle/_comparison.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/src/tensoracle/bundle.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/src/tensoracle/convert.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/src/tensoracle/producer.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/cubin_io/check.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/cubins/ptxas-12.9.86/sm120.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/cubins/ptxas-12.9.86/sm86.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/cubins/ptxas-12.9.86/sm89.cubin +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/native/CMakeLists.txt +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/native/cache/CMakeLists.txt +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/native/cache/writer.cpp +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/native/export.h +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/native_build.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_bundle.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_cache_cli.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_cmake_cuda.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_cmake_plugin.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_comparison.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_comparison_binding.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_convert.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_cpp_core.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_example_plugin.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_native.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_plugin_io.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_producer.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/tests/test_public_api.py +0 -0
- {tensoracle-2.1.1 → tensoracle-2.1.2}/uv.lock +0 -0
|
@@ -31,6 +31,14 @@ endif()
|
|
|
31
31
|
add_subdirectory("${_cpp}" cpp)
|
|
32
32
|
nanobind_add_module(_native STABLE_ABI bindings.cpp cubin_bindings.cpp)
|
|
33
33
|
target_link_libraries(_native PRIVATE tensoracle::tensoracle)
|
|
34
|
+
# The build tree keeps the module under tensoracle/ so the stub generator imports it by the
|
|
35
|
+
# package name that its exception classes record.
|
|
34
36
|
set_target_properties(_native PROPERTIES
|
|
37
|
+
LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensoracle"
|
|
35
38
|
BUILD_RPATH_USE_ORIGIN YES INSTALL_RPATH "$ORIGIN/cpp/lib")
|
|
36
39
|
install(TARGETS _native LIBRARY DESTINATION tensoracle RUNTIME DESTINATION tensoracle)
|
|
40
|
+
# The build RPATH finds libtensoracle and the TensorRT wheel while the stub is generated.
|
|
41
|
+
# Private names are kept because public signatures return _CacheResult.
|
|
42
|
+
nanobind_add_stub(_native_stub MODULE tensoracle._native OUTPUT _native.pyi
|
|
43
|
+
PYTHON_PATH "${CMAKE_CURRENT_BINARY_DIR}" DEPENDS _native INCLUDE_PRIVATE)
|
|
44
|
+
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/_native.pyi" DESTINATION tensoracle)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tensoracle
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.2
|
|
4
4
|
Summary: Build, save, reuse, and execute TensorRT engines from safetensors weights
|
|
5
5
|
Author-Email: minamik <mia@sync.dev>
|
|
6
6
|
License-Expression: MIT
|
|
@@ -50,7 +50,7 @@ Read the [v2 user guide](https://sync-dev-org.github.io/tensoracle/) and [Migrat
|
|
|
50
50
|
| Model package developer | Open and execute engines through tensoracle's C++ SDK, exposing inference through your own binding. | TensorRT 11 headers, CMake 3.26 or later, C++17 compiler, and a binding framework when needed. |
|
|
51
51
|
| Cubin plugin developer | Compile CUDA C++ kernels and package a native plugin with the model. | `tensoracle[producer]`, PyPI CUDA headers and tools, TensorRT SDK, CMake, and a C++17 compiler. |
|
|
52
52
|
|
|
53
|
-
v2
|
|
53
|
+
v2 supplies a Linux x86_64 `manylinux_2_28`, `cp312-abi3` wheel, including WSL2. The package currently declares Python 3.12 and 3.13 support. Target GPUs are sm86, sm89, and sm120 with TensorRT 11; fp8 requires sm89 or sm120. Windows x86_64 users must keep using tensoracle 1.x until a later v2 minor release adds a Windows wheel.
|
|
54
54
|
|
|
55
55
|
The wheel contains the C++ public headers, `libtensoracle`, CMake package configuration, and cubin plugin helper sources. TensorRT is resolved through a wheel dependency; the NVIDIA driver is not bundled. Public C++ interfaces and saved engine files remain compatible within a major version.
|
|
56
56
|
|
|
@@ -18,7 +18,7 @@ Read the [v2 user guide](https://sync-dev-org.github.io/tensoracle/) and [Migrat
|
|
|
18
18
|
| Model package developer | Open and execute engines through tensoracle's C++ SDK, exposing inference through your own binding. | TensorRT 11 headers, CMake 3.26 or later, C++17 compiler, and a binding framework when needed. |
|
|
19
19
|
| Cubin plugin developer | Compile CUDA C++ kernels and package a native plugin with the model. | `tensoracle[producer]`, PyPI CUDA headers and tools, TensorRT SDK, CMake, and a C++17 compiler. |
|
|
20
20
|
|
|
21
|
-
v2
|
|
21
|
+
v2 supplies a Linux x86_64 `manylinux_2_28`, `cp312-abi3` wheel, including WSL2. The package currently declares Python 3.12 and 3.13 support. Target GPUs are sm86, sm89, and sm120 with TensorRT 11; fp8 requires sm89 or sm120. Windows x86_64 users must keep using tensoracle 1.x until a later v2 minor release adds a Windows wheel.
|
|
22
22
|
|
|
23
23
|
The wheel contains the C++ public headers, `libtensoracle`, CMake package configuration, and cubin plugin helper sources. TensorRT is resolved through a wheel dependency; the NVIDIA driver is not bundled. Public C++ interfaces and saved engine files remain compatible within a major version.
|
|
24
24
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The v2 wheel supplies a shared C++ library, public headers, CMake package configuration, and source-based cubin plugin helpers. Your model package defines the TensorRT network and engine-opening code in C++, links the shared library, and exposes inference through its own binding. For custom plugins it also supplies CUDA C++ kernels and model-specific plugin behavior.
|
|
4
4
|
|
|
5
|
-
v2
|
|
5
|
+
v2 is available on Linux x86_64, including WSL2, as a `manylinux_2_28`, `cp312-abi3` wheel. Windows x86_64 users must use tensoracle 1.x until a later v2 minor release adds a Windows wheel.
|
|
6
6
|
|
|
7
7
|
## C++ SDK in the wheel
|
|
8
8
|
|
|
@@ -21,7 +21,7 @@ If your model package uses tensoracle 1.x, start with [Migrate from 1.x](migrati
|
|
|
21
21
|
| Cubin plugin developer | [Produce cubins and build a plugin](#build-a-cubin-plugin). | `tensoracle[producer]` for generation, TensorRT SDK headers and libraries, PyPI CUDA headers and tools, and the plugin's C++ build. |
|
|
22
22
|
| Output validation | Compare CPU NumPy outputs with [the comparison API](api/index.md#output-comparison). | The application runs the engines and chooses the quality limits. |
|
|
23
23
|
|
|
24
|
-
v2
|
|
24
|
+
v2 supplies a Linux x86_64 `manylinux_2_28` wheel, including WSL2, with the `cp312-abi3` tag. The package currently declares Python 3.12 and 3.13 support. TensorRT 11 and GPU generations sm86, sm89, and sm120 are the targets; fp8 requires sm89 or sm120. Windows x86_64 users must use tensoracle 1.x until a later v2 minor release supplies a Windows wheel. A Linux wheel runs under WSL2, not directly in Windows Python.
|
|
25
25
|
|
|
26
26
|
The wheel includes the shared C++ library, public headers, CMake package configuration, and source-based cubin plugin helpers. It resolves TensorRT through its wheel dependency rather than bundling TensorRT or the NVIDIA driver. The C ABI uses opaque handles and structures with `struct_size`; the C++ headers add exceptions and automatic resource release. Public C++ interfaces and saved engine files remain compatible within the same major version.
|
|
27
27
|
|
|
@@ -4,7 +4,7 @@ tensoracle v2 moves engine construction, saving and reuse, execution, and plugin
|
|
|
4
4
|
|
|
5
5
|
## Check the platform first
|
|
6
6
|
|
|
7
|
-
v2
|
|
7
|
+
v2 supplies only a Linux x86_64 `manylinux_2_28` wheel with the `cp312-abi3` tag. It includes the C++ shared library, public headers, and CMake package configuration. The package currently declares Python 3.12 and 3.13 support. TensorRT 11 and sm86, sm89, and sm120 remain the targets; fp8 requires sm89 or sm120.
|
|
8
8
|
|
|
9
9
|
Windows x86_64 users must stay on tensoracle 1.x until a later v2 minor release adds a Windows wheel. Use `tensoracle<2` in a Windows application's dependency declaration during that period. WSL2 can use the Linux wheel inside its Linux Python environment.
|
|
10
10
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Prepare a TensorRT SDK
|
|
2
2
|
|
|
3
|
-
Use the Linux procedure below to prepare the headers and `libnvinfer` needed to build a C++ model package or native cubin plugin on Linux x86_64, including WSL2. v2
|
|
3
|
+
Use the Linux procedure below to prepare the headers and `libnvinfer` needed to build a C++ model package or native cubin plugin on Linux x86_64, including WSL2. v2 supplies only a Linux wheel; [Windows x86_64 users](#windows-x86_64) must stay on tensoracle 1.x until a later v2 minor release adds a Windows wheel. The Linux SDK root contains 13 headers in `include/`, `lib/libnvinfer.so.11`, and a relative `lib/libnvinfer.so` symlink pointing to `libnvinfer.so.11`. CMake (3.26 or later for the v2 SDK), a C++17 compiler, and the CUDA headers from PyPI are separate build prerequisites; no OS-installed CUDA Toolkit is required. TensorRT headers are absent from the Python wheels and must be prepared separately. Normal engine reuse does not need this SDK root.
|
|
4
4
|
|
|
5
5
|
The inputs below are fixed for SDK **11.2.1.2**: headers from a release commit of [NVIDIA TensorRT OSS](https://github.com/NVIDIA/TensorRT), and the exact `tensorrt-cu13-libs` wheel from [NVIDIA's package index](https://pypi.nvidia.com/tensorrt-cu13-libs/). The wheel platform is `manylinux_2_28_x86_64`; use that file rather than an aarch64 or Windows wheel.
|
|
6
6
|
|
|
@@ -122,4 +122,4 @@ Use the same acquisition and verification steps for another TensorRT 11 release,
|
|
|
122
122
|
|
|
123
123
|
## Windows x86_64
|
|
124
124
|
|
|
125
|
-
v2
|
|
125
|
+
v2 has no Windows wheel yet. Keep Windows Python applications on tensoracle 1.x until a later v2 minor release supplies one. Preparing Windows TensorRT headers does not make the Linux v2 wheel installable in Windows Python. WSL2 users can follow the Linux SDK procedure inside their Linux environment. See [Migrate from 1.x](migration.md#check-the-platform-first) for platform and package requirements.
|
|
@@ -18,7 +18,7 @@ version_tuple: tuple[int | str, ...]
|
|
|
18
18
|
commit_id: str | None
|
|
19
19
|
__commit_id__: str | None
|
|
20
20
|
|
|
21
|
-
__version__ = version = '2.1.
|
|
22
|
-
__version_tuple__ = version_tuple = (2, 1,
|
|
21
|
+
__version__ = version = '2.1.2'
|
|
22
|
+
__version_tuple__ = version_tuple = (2, 1, 2)
|
|
23
23
|
|
|
24
24
|
__commit_id__ = commit_id = None
|
|
File without changes
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"""Check the files and public metadata delivered through PyPI."""
|
|
2
2
|
|
|
3
|
+
import ast
|
|
3
4
|
import configparser
|
|
4
5
|
import email
|
|
5
6
|
import json
|
|
@@ -345,6 +346,59 @@ def test_installed_wheel_serves_python_and_cpp_without_the_source_tree(distribut
|
|
|
345
346
|
subprocess.run(command, cwd=tmp_path, env=environment, check=True, timeout=45)
|
|
346
347
|
|
|
347
348
|
|
|
349
|
+
@pytest.mark.req("SP-TENSORACLE-062")
|
|
350
|
+
def test_wheel_types_the_native_module_with_a_matching_stub(distributions, tmp_path):
|
|
351
|
+
"""The wheel marks the package as typed and its stub declares exactly the native names."""
|
|
352
|
+
with zipfile.ZipFile(distributions["wheel"]) as archive:
|
|
353
|
+
assert "tensoracle/py.typed" in archive.namelist()
|
|
354
|
+
stub = ast.parse(archive.read("tensoracle/_native.pyi").decode("utf-8"))
|
|
355
|
+
declared = {}
|
|
356
|
+
for node in stub.body:
|
|
357
|
+
if isinstance(node, ast.ClassDef):
|
|
358
|
+
declared[node.name] = [ast.unparse(base) for base in node.bases] or ["object"]
|
|
359
|
+
elif isinstance(node, ast.FunctionDef):
|
|
360
|
+
declared[node.name] = None
|
|
361
|
+
elif isinstance(node, ast.AnnAssign) and isinstance(node.target, ast.Name):
|
|
362
|
+
declared[node.target.id] = None
|
|
363
|
+
elif isinstance(node, ast.Assign):
|
|
364
|
+
declared.update(
|
|
365
|
+
(target.id, None) for target in node.targets if isinstance(target, ast.Name)
|
|
366
|
+
)
|
|
367
|
+
runtime = tmp_path / "runtime"
|
|
368
|
+
subprocess.run(["uv", "venv", "--python", sys.executable, str(runtime)], check=True)
|
|
369
|
+
python = runtime / "bin/python"
|
|
370
|
+
subprocess.run(
|
|
371
|
+
["uv", "pip", "install", "--python", str(python), str(distributions["wheel"])],
|
|
372
|
+
check=True,
|
|
373
|
+
timeout=120,
|
|
374
|
+
)
|
|
375
|
+
result = subprocess.run(
|
|
376
|
+
[
|
|
377
|
+
str(python),
|
|
378
|
+
"-I",
|
|
379
|
+
"-c",
|
|
380
|
+
(
|
|
381
|
+
"import json; from tensoracle import _native; "
|
|
382
|
+
"values = {name: getattr(_native, name) for name in dir(_native)}; "
|
|
383
|
+
"print(json.dumps({name: [base.__name__ for base in value.__bases__] "
|
|
384
|
+
"if isinstance(value, type) else None "
|
|
385
|
+
"for name, value in values.items() if not name.startswith('__')}))"
|
|
386
|
+
),
|
|
387
|
+
],
|
|
388
|
+
cwd=tmp_path,
|
|
389
|
+
check=True,
|
|
390
|
+
capture_output=True,
|
|
391
|
+
text=True,
|
|
392
|
+
)
|
|
393
|
+
native = json.loads(result.stdout)
|
|
394
|
+
public = {name for name in native if not name.startswith("_")}
|
|
395
|
+
assert {"BundleError", "CubinArchitectureError", "compare_outputs", "cache_list"} <= public
|
|
396
|
+
assert public <= declared.keys()
|
|
397
|
+
assert declared.keys() <= native.keys()
|
|
398
|
+
classes = {name: bases for name, bases in declared.items() if bases is not None}
|
|
399
|
+
assert classes == {name: native[name] for name in classes}
|
|
400
|
+
|
|
401
|
+
|
|
348
402
|
@pytest.fixture(scope="module")
|
|
349
403
|
def consumer_wheel(distributions, tmp_path_factory):
|
|
350
404
|
"""Build a separate binding against the wheel in a PEP 517 build environment."""
|
|
@@ -697,8 +751,9 @@ def test_backend_removes_staging_files_after_metadata_failure(tmp_path):
|
|
|
697
751
|
|
|
698
752
|
|
|
699
753
|
@pytest.mark.req("SP-TENSORACLE-021")
|
|
754
|
+
@pytest.mark.req("SP-TENSORACLE-062")
|
|
700
755
|
def test_sdist_rebuilds_the_complete_wheel_without_the_repository(distributions, tmp_path):
|
|
701
|
-
"""An extracted sdist builds the same package, metadata, and C++ sources
|
|
756
|
+
"""An extracted sdist builds the same package, metadata, typing files, and C++ sources."""
|
|
702
757
|
with tarfile.open(distributions["sdist"]) as archive:
|
|
703
758
|
archive.extractall(tmp_path, filter="data")
|
|
704
759
|
source = next(path for path in tmp_path.iterdir() if path.is_dir())
|
|
@@ -708,10 +763,10 @@ def test_sdist_rebuilds_the_complete_wheel_without_the_repository(distributions,
|
|
|
708
763
|
zipfile.ZipFile(distributions["wheel"]) as original,
|
|
709
764
|
zipfile.ZipFile(next(output.glob("*.whl"))) as rebuilt,
|
|
710
765
|
):
|
|
766
|
+
assert {"tensoracle/py.typed", "tensoracle/_native.pyi"} <= set(rebuilt.namelist())
|
|
711
767
|
assert set(original.namelist()) == set(rebuilt.namelist())
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
)
|
|
768
|
+
for member in ("tensoracle/_native.pyi", "tensoracle/cpp/src/cubin_plugin.cpp"):
|
|
769
|
+
assert original.read(member) == rebuilt.read(member), member
|
|
715
770
|
name = next(name for name in original.namelist() if name.endswith(".dist-info/METADATA"))
|
|
716
771
|
assert original.read(name) == rebuilt.read(name)
|
|
717
772
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm86/dot.specialized.cubin
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/bundle/cubins/sm89/dot.specialized.cubin
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/example_cubin_plugin/__init__.py
RENAMED
|
File without changes
|
{tensoracle-2.1.1 → tensoracle-2.1.2}/examples/cubin_plugin/example_cubin_plugin/weights.safetensors
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{tensoracle-2.1.1 → tensoracle-2.1.2}/examples/wheel_consumer/src/tensoracle_consumer/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|