-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,7 +28,7 @@ Optional: | |
|
||
Run the steps below to build documentation locally. | ||
|
||
```shell | ||
```bash | ||
cd docs | ||
|
||
pip3 install -r .sphinx/requirements.txt | ||
|
@@ -38,15 +38,36 @@ python3 -m sphinx -T -E -b html -d _build/doctrees -D language=en . _build/html | |
|
||
## Currently supported | ||
|
||
Operations - Contraction Tensor | ||
Data Types - FP32 , FP64 | ||
### Operations - Contraction Tensor | ||
|
||
Supported data-type combinations are: | ||
|
||
| typeA | typeB | typeC | typeCompute | notes | | ||
|-----------|-----------|-----------|-----------------|----------------------------------| | ||
| bf16 | bf16 | bf16 | f32 | | | ||
| __half | __half | __half | f32 | | | ||
| f32 | f32 | f32 | bf16 | | | ||
| f32 | f32 | f32 | __half | | | ||
| f32 | f32 | f32 | f32 | | | ||
| f64 | f64 | f64 | f32 | f64 is supported only on gfx90 + | | ||
| f64 | f64 | f64 | f64 | f64 is supported only on gfx90 + | | ||
|
||
### Operations - Permutation Tensor | ||
|
||
Supported data-type combinations are: | ||
|
||
| typeA | typeB | descCompute | notes | | ||
|-----------|-----------|-----------------|-------| | ||
| f16 | f16 | f16 | | | ||
| f16 | f16 | f32 | | | ||
| f32 | f32 | f32 | | | ||
|
||
## Contributing to the code | ||
|
||
1. Create and track a hipTensor fork. | ||
2. Clone your fork: | ||
|
||
```shell | ||
```bash | ||
git clone -b develop https://github.com/<your_fork>/hipTensor.git . | ||
.githooks/install | ||
git checkout -b <new_branch> | ||
|
@@ -69,22 +90,22 @@ git push origin <new_branch> | |
|
||
### Project options | ||
|
||
|Option|Description|Default Value| | ||
|---|---|---| | ||
|AMDGPU_TARGETS|Build code for specific GPU target(s)|gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx940;gfx941;gfx942| | ||
|HIPTENSOR_BUILD_TESTS|Build Tests|ON| | ||
|HIPTENSOR_BUILD_SAMPLES|Build Samples|ON| | ||
| Option | Description | Default Value | | ||
|-------------------------|---------------------------------------|----------------------------------------------------------------| | ||
| AMDGPU_TARGETS | Build code for specific GPU target(s) | gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx940;gfx941;gfx942 | | ||
| HIPTENSOR_BUILD_TESTS | Build Tests | ON | | ||
| HIPTENSOR_BUILD_SAMPLES | Build Samples | ON | | ||
|
||
### Example configurations | ||
|
||
By default, the project is configured as Release mode. | ||
Here are some of the examples for the configuration: | ||
|Configuration|Command| | ||
|---|---| | ||
|Basic|`CC=hipcc CXX=hipcc cmake -B<build_dir> .`| | ||
|Targeting gfx908|`CC=hipcc CXX=hipcc cmake -B<build_dir> . -DAMDGPU_TARGETS=gfx908:xnack-` | | ||
|Debug build|`CC=hipcc CXX=hipcc cmake -B<build_dir> . -DCMAKE_BUILD_TYPE=Debug` | | ||
|Build without tests (default on)|`CC=hipcc CXX=hipcc cmake -B<build_dir> . -DHIPTENSOR_BUILD_TESTS=OFF` | | ||
| Configuration | Command | | ||
|----------------------------------|---------------------------------------------------------------------------| | ||
| Basic | `CC=hipcc CXX=hipcc cmake -B<build_dir> .` | | ||
| Targeting gfx908 | `CC=hipcc CXX=hipcc cmake -B<build_dir> . -DAMDGPU_TARGETS=gfx908:xnack-` | | ||
| Debug build | `CC=hipcc CXX=hipcc cmake -B<build_dir> . -DCMAKE_BUILD_TYPE=Debug` | | ||
| Build without tests (default on) | `CC=hipcc CXX=hipcc cmake -B<build_dir> . -DHIPTENSOR_BUILD_TESTS=OFF` | | ||
|
||
After configuration, build with `cmake --build <build_dir> -- -j<nproc>` | ||
|
||
|
@@ -98,40 +119,63 @@ After configuration, build with `cmake --build <build_dir> -- -j<nproc>` | |
### Logger tests | ||
|
||
Tests API implementation of logger verbosity and functionality. | ||
o <build_dir>/bin/logger_test | ||
```bash | ||
Check failure on line 122 in README.md GitHub Actions / Documentation / MarkdownFenced code blocks should be surrounded by blank lines
|
||
<build_dir>/bin/logger_test | ||
``` | ||
|
||
## Running Contraction Tests | ||
|
||
### Bilinear contraction tests | ||
|
||
Tests the API implementation of bilinear contraction algorithm with validation. | ||
o <build_dir>/bin/bilinear_contraction_f32_test | ||
o <build_dir>/bin/bilinear_contraction_f64_test | ||
```bash | ||
Check failure on line 131 in README.md GitHub Actions / Documentation / MarkdownFenced code blocks should be surrounded by blank lines
|
||
<build_dir>/bin/bilinear_contraction_test | ||
``` | ||
|
||
### Scale contraction tests | ||
|
||
Tests the API implementation of scale contraction algorithm with validation. | ||
o <build_dir>/bin/scale_contraction_f32_test | ||
o <build_dir>/bin/scale_contraction_f64_test | ||
```bash | ||
Check failure on line 138 in README.md GitHub Actions / Documentation / MarkdownFenced code blocks should be surrounded by blank lines
|
||
<build_dir>/bin/scale_contraction_test | ||
``` | ||
|
||
### Samples | ||
## Running Permutation Tests | ||
|
||
### Permutation tests | ||
Check failure on line 144 in README.md GitHub Actions / Documentation / MarkdownHeadings should be surrounded by blank lines
|
||
Tests API implementation of permutation algorithm with validation. | ||
```bash | ||
Check failure on line 146 in README.md GitHub Actions / Documentation / MarkdownFenced code blocks should be surrounded by blank lines
|
||
<build_dir>/bin/permutation_test | ||
``` | ||
|
||
## Samples | ||
|
||
These are stand-alone use-cases of the hipTensor contraction operations. | ||
|
||
## F32 Bilinear contraction | ||
### F32 Bilinear contraction | ||
|
||
Demonstrates the API implementation of bilinear contraction operation without validation. | ||
o <build_dir>/bin/simple_contraction_bilinear_f32 | ||
```bash | ||
Check failure on line 157 in README.md GitHub Actions / Documentation / MarkdownFenced code blocks should be surrounded by blank lines
|
||
<build_dir>/bin/simple_bilinear_contraction_<typeA>_<typeB>_<typeC>_<typeD>_compute_<computeType> | ||
``` | ||
|
||
## F32 Scale contraction | ||
### F32 Scale contraction | ||
|
||
Demonstrates the API implementation of scale contraction operation without validation. | ||
o <build_dir>/bin/simple_contraction_scale_f32 | ||
```bash | ||
Check failure on line 164 in README.md GitHub Actions / Documentation / MarkdownFenced code blocks should be surrounded by blank lines
|
||
<build_dir>/bin/simple_scale_contraction_<typeA>_<typeB>_<typeD>_compute_<typeCompute> | ||
``` | ||
|
||
### Permutation | ||
|
||
Demonstrates the API implementation of permutation operation without validation. | ||
```bash | ||
Check failure on line 171 in README.md GitHub Actions / Documentation / MarkdownFenced code blocks should be surrounded by blank lines
|
||
<build_dir>/bin/simple_permutation | ||
``` | ||
|
||
### Build Samples as external client | ||
|
||
Client application links to hipTensor library, | ||
and therefore hipTensor library needs to be installed before building client applications. | ||
Client application links to hipTensor library, and therefore hipTensor library | ||
needs to be installed before building client applications. | ||
|
||
## Build | ||
|
||
|