Spaces:
Sleeping
Sleeping
Download src/acceleration/cuda/memory.py from ThomasHeisig/MHRN-Space: direct link, hf CLI and curl.
- Browser
- Download file 260 Bytes
-
https://huggingface.co/spaces/ThomasHeisig/MHRN-Space/resolve/main/src/acceleration/cuda/memory.py
- Command line
-
hf download hf://spaces/ThomasHeisig/MHRN-Space/src/acceleration/cuda/memory.py
-
curl -L -o memory.py https://huggingface.co/spaces/ThomasHeisig/MHRN-Space/resolve/main/src/acceleration/cuda/memory.py
260 Bytes
| """Canonical CUDA memory ownership contracts.""" | |
| from __future__ import annotations | |
| from dataclasses import dataclass | |
| class DeviceAllocation: | |
| """One owned CUDA device allocation.""" | |
| ptr: int | |
| size_bytes: int | |