VCSparse: Generate fused and vectorizable kernels for sparse tensor programs on CPUs and GPUs. An web tool is available to try VCSparse online: https://tongzhou80.github.io/vcsparse-web/index.html.
More technical detals are to be added!
Installation
pip install vcsparse
Quick introduction
To compile a function with vcsparse, all you need to do is to add index notation to the function arguments,
and decorate the function with @vcsparse.compile. Here's an example:
@vcsparse.compile(full_opt=True)
def mul_then_rowwise_sum(A: Tensor('i,j', 'csr'), B: Tensor('i,j', 'csr')):
return (A * B).sum(1)
The option full_opt=True will enable all optimization passes. The directory tests/ contains many code examples of using VCSparse, feel free to check them out.
Note
Currently only a CPU backend (via Numba) is implemented. A GPU backend (via APPy) is under development.
Metadata
Release files for vcsparse 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| vcsparse-0.1.2.tar.gz | 20.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| vcsparse-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 69.6 kB
Release files / vcsparse-0.1.2.tar.gz
| Download URL | vcsparse-0.1.2.tar.gz |
|---|---|
| Size | 20.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3eedffaa946648b4d0e5c413cd2acfc1ca360cf76b88ce19a79e0afd9eaf13bc
|
|
BLAKE2b-256 checksum How to use checksums |
ab077f3fc8297df5e2a59888a3c3af34cfb651bb35b269391debe1cb3db9e4a5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.12.4
|
Release files / vcsparse-0.1.2-py3-none-any.whl
| Download URL | vcsparse-0.1.2-py3-none-any.whl |
|---|---|
| Size | 49.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8a46cfb87c3c3d9e0dcf1925836f8c45378b59e0c0ac8e09b3f319f6241cba7b
|
|
BLAKE2b-256 checksum How to use checksums |
fa353f28030830786db6a11117d5cea2f642245b4908ccbd33e8b6a7403ac734
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.12.4
|