Instructions to use cahlen/flint-hills-cuda with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Kernels
How to use cahlen/flint-hills-cuda with Kernels:
# !pip install kernels from kernels import get_kernel # a version (or an explicit revision) is required; see the "Files and versions" tab for the available ones kernel = get_kernel("cahlen/flint-hills-cuda", version=1) - Notebooks
- Google Colab
- Kaggle
Download scripts/test.py from cahlen/flint-hills-cuda: direct link, hf CLI and curl.
- Browser
- Download file 427 Bytes
-
https://huggingface.co/cahlen/flint-hills-cuda/resolve/main/scripts/test.py
- Command line
-
hf download hf://cahlen/flint-hills-cuda/scripts/test.py
-
curl -L -o test.py https://huggingface.co/cahlen/flint-hills-cuda/resolve/main/scripts/test.py
427 Bytes
| """CPU-only verification test for Flint Hills Series""" | |
| print("Testing flint-hills-cuda...") | |
| import math | |
| S10 = sum(1.0 / (n**3 * math.sin(n)**2) for n in range(1, 11)) | |
| print(f" S_10 = {S10:.6f}") | |
| assert 3.0 < S10 < 4.0, f"S_10 out of expected range: {S10}" | |
| S100 = sum(1.0 / (n**3 * math.sin(n)**2) for n in range(1, 101)) | |
| print(f" S_100 = {S100:.6f}") | |
| assert S100 > S10, "S_100 should be > S_10" | |
| print(f"\n2/2 tests passed") | |