Installation
TileFusion can be used as a lightweight C++ library with header-only usage, or it can be built as a Python library. You can choose to build either one.
Prerequisites
TileFusion requires:
- C++20 host compiler
- CUDA 12.0 or later
- GCC version 10.0 or higher to support C++20 features
Download the repository:
git clone git@github.com:microsoft/TileFusion.git
cd TileFusion && git submodule update --init --recursive
Building the C++ Library
To build the project using the provided Makefile
, simply run:
make
To run a single C++ unit test:
make unit_test_cpp CPP_UT=test_gemm
Building the Python Package
-
Build the wheel:
python setup.py build bdist_wheel
-
Clean the build:
python setup.py clean
-
Install the Python package in editable mode (recommended for development):
python setup.py develop
This allows you to edit the source code directly without needing to reinstall it repeatedly.
Running Unit Tests
Before running the Python unit tests, you need to build and install the Python package (see the Building the Python Package section).
-
Run a single Python unit test:
pytest tests/python/test_scatter_nd.py
-
Run all Python unit tests:
python setup.py pytests
-
Run all C++ unit tests:
python setup.py ctests