https://github.com/spcl/spatial-collectives
Optimized communication collectives for the Cerebras waferscale engine
https://github.com/spcl/spatial-collectives
Last synced: 9 months ago
JSON representation
Optimized communication collectives for the Cerebras waferscale engine
- Host: GitHub
- URL: https://github.com/spcl/spatial-collectives
- Owner: spcl
- Created: 2023-11-07T13:47:48.000Z (about 2 years ago)
- Default Branch: master
- Last Pushed: 2024-06-05T15:49:52.000Z (over 1 year ago)
- Last Synced: 2025-03-22T19:45:07.359Z (10 months ago)
- Language: Python
- Size: 55.7 KB
- Stars: 5
- Watchers: 7
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Spatial Collectives
This repository contains code to reproduce the key results of the paper "Near-Optimal Wafer-Scale Reduce".
The codes are made to work with SDK version 1.0 and work on the simulator and CS-2.
### Benchmarks
Each benchmark starts with `commands_... .sh`. The provided commands are written to work with the simulator. They can easily be extended to run on the hardware. We provide an example slurm command.
## Usage
We provide usage examples, but in general you need to
1. Initialize the library with the respective collective
```
const reduce_left = @import_module("modules/chain_sync.csl", .{.color_1 = @get_color(4), .color_2 = @get_color(5), .pe_id = pe_id, .POS_DIR = EAST, .NEG_DIR = WEST, .NUM_PES = Pw});
```
2. Configure the network
```
reduce_left.configure_network();
```
3. Call the collective, providing a color, which will be activated at the end of the call
```
reduce_left.transfer_data(data_ptr, Nx, execution_color);
```
### Cite
If you found this work useful, please consider citing: