An open API service indexing awesome lists of open source software.

https://github.com/0xhilsa/vector.py-cuda

a python lib for vector with GPU support
https://github.com/0xhilsa/vector.py-cuda

cuda-support cuda-toolkit python311 vector

Last synced: 5 months ago
JSON representation

a python lib for vector with GPU support

Awesome Lists containing this project

README

          

vector.py

## Usage:

```python
import vector_cuda as vc

x = vc.vector([1,2,3,4],device = "cuda")
y = vc.vector([1,2,3,4]) # by default the device will be set as CPU

print(x) # output:
print(x.array()) # output: [1 2 3 4]

print(y) # output:
print(y.array()) # output: [1 2 3 4]
```

## Requirements:
- [NVIDIA-Toolkit](https://developer.nvidia.com/cuda-downloads) must be installed on your system
- nvcc compiler
- python >= 3.6

## Installation:

1. clone this repo
```bash
git clone "https://github.com/Sahil-Rajwar-2004/vector.py-CUDA.git"
```

2. navigate to vector directory that you just downloaded/cloned

3. see below instruction for different OS:

### Windows Users:

run `install.ps1` script on your current working directory

```powershell
pwsh install.ps1
```

### Linux / MacOS:

run `install.sh` script on your current working directory

```bash
bash install.sh
```

## LICENSE

### MIT