Skip to content

Commit 4602778

Browse files
committed
Update README
1 parent 9b423f7 commit 4602778

File tree

2 files changed

+38
-42
lines changed

2 files changed

+38
-42
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22

33
CUDA Python is the home for accessing NVIDIA’s CUDA platform from Python. It consists of multiple components:
44

5-
[cuda.core](https://nvidia.github.io/cuda-python/cuda-core/latest): Pythonic access to CUDA Runtime and other core functionalities
6-
[cuda.bindings](https://nvidia.github.io/cuda-python/cuda-bindings/latest): Low-level Python bindings to CUDA C APIs
7-
[cuda.cooperative](https://nvidia.github.io/cccl/cuda_cooperative/): Pythonic exposure of CUB cooperative algorithms
8-
[cuda.parallel](https://nvidia.github.io/cccl/cuda_parallel/): Pythonic exposure of Thrust parallel algorithms
5+
* [cuda.core](https://nvidia.github.io/cuda-python/cuda-core/latest): Pythonic access to CUDA Runtime and other core functionalities
6+
* [cuda.bindings](https://nvidia.github.io/cuda-python/cuda-bindings/latest): Low-level Python bindings to CUDA C APIs
7+
* [cuda.cooperative](https://nvidia.github.io/cccl/cuda_cooperative/): Pythonic exposure of CUB cooperative algorithms
8+
* [cuda.parallel](https://nvidia.github.io/cccl/cuda_parallel/): Pythonic exposure of Thrust parallel algorithms
99

1010
For access to NVIDIA Math Libraries, please refer to [nvmath-python](https://docs.nvidia.com/cuda/nvmath-python/latest).
1111

@@ -31,7 +31,7 @@ The goals are to
3131

3232
The cuda.bindings package is a standard set of low-level interfaces, providing full coverage of and access to the CUDA host APIs from Python.
3333

34-
Available interfaces are
34+
The list of available interfaces are:
3535

3636
* CUDA Driver
3737
* CUDA Runtime

cuda_bindings/README.md

Lines changed: 33 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -31,57 +31,41 @@ Source builds work for multiple Python versions, however pre-build PyPI and Cond
3131

3232
* Python 3.9 to 3.12
3333

34-
## Testing (Cython)
35-
36-
Cython tests are located under `tests/cython`.
34+
## Testing
3735

3836
Latest dependencies can be found in [requirements.txt](https://github.com/NVIDIA/cuda-python/blob/main/cuda_bindings/requirements.txt).
3937

40-
## Testing (Python)
38+
Multiple testing options are available:
4139

42-
Latest dependencies can be found in [requirements.txt](https://github.com/NVIDIA/cuda-python/blob/main/cuda_bindings/requirements.txt).
40+
* Cython Unit Tests
41+
* Python Unit Tests
42+
* Samples
43+
* Benchmark
4344

44-
### Unit-tests
45+
### Python Unit Tests
4546

46-
To run unit-tests against local builds:
47-
```
48-
python -m pytest tests/
49-
```
50-
To run unit-tests against installed builds:
51-
```
52-
pytest tests/
53-
```
47+
Responsible for validating different binding usage patterns. Unit test `test_kernelParams.py` is particularly special since it demonstrates various approaches in setting up kernel launch parameters.
5448

55-
### Unit-tests
49+
To run these tests:
50+
* `python -m pytest tests/` against local builds
51+
* `pytest tests/` against installed package
5652

53+
### Cython Unit Tests
5754

58-
### Benchmark
55+
Cython tests are located under `tests/cython` and need to be built. Furthermore they need CUDA Toolkit headers matching the major-minor of CUDA Python. To build them:
5956

60-
To run unit-tests against local builds:
61-
```
62-
python -m pytest --benchmark-only benchmark/
63-
```
64-
To run unit-tests against installed builds:
65-
```
66-
pytest --benchmark-only benchmark/
67-
```
57+
1. Setup environment variable `CUDA_HOME` with the path to the CUDA Toolkit installation.
58+
2. Run `build_tests` script located in `test/cython` appropriate to your platform. This will both Cythonize the tests and build them.
6859

69-
### Samples
60+
To run these tests:
61+
* `python -m pytest tests/cython/` against local builds
62+
* `pytest tests/cython/` against installed package
7063

71-
To run unit-tests against local builds:
72-
```
73-
python -m pytest benchmark/
74-
```
75-
To run unit-tests against installed builds:
76-
```
77-
pytest benchmark/
78-
```
79-
80-
## Examples
64+
### Samples
8165

82-
[CUDA Samples](https://github.com/NVIDIA/cuda-samples/tree/master) rewriten using CUDA Python are found in `examples`.
66+
Various [CUDA Samples](https://github.com/NVIDIA/cuda-samples/tree/master) that were rewritten using CUDA Python can be found in `examples`.
8367

84-
Custom extra included examples:
68+
In addition, extra examples are included:
8569

8670
* `examples/extra/jit_program_test.py`: Demonstrates the use of the API to compile and
8771
launch a kernel on the device. Includes device memory allocation /
@@ -90,3 +74,15 @@ Custom extra included examples:
9074
* `examples/extra/numba_emm_plugin.py`: Implements a Numba External Memory Management
9175
plugin, showing that this CUDA Python Driver API can coexist with other
9276
wrappers of the driver API.
77+
78+
To run these samples:
79+
* `python -m pytest tests/cython/` against local builds
80+
* `pytest tests/cython/` against installed package
81+
82+
### Benchmark (WIP)
83+
84+
Benchmarks were used for performance analysis during initial release of CUDA Python. Today they need to be updated the 12.x toolkit and are work in progress.
85+
86+
The intended way to run these benchmarks was:
87+
* `python -m pytest --benchmark-only benchmark/` against local builds
88+
* `pytest --benchmark-only benchmark/` against installed package

0 commit comments

Comments
 (0)