This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ray | |
import ray.dag | |
@ray.remote | |
class Worker: | |
def __init__(self, rank): | |
self.rank = rank | |
self.trace = [] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ray | |
import time | |
@ray.remote(num_cpus=0) | |
class Counter: | |
def __init__(self): | |
self.num_f = 0 | |
self.num_g = 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Runs single-node microbenchmarks for reading and preprocessing an image dataset | |
from local disk and (for supported data loaders) cloud storage. Pass a --data-root, | |
--parquet-data-root, --tf-data-root, and/or --mosaic-data-root pointing to the | |
dataset directory. Throughputs are written to `output.csv` in total images/s. | |
""" | |
import ray | |
import torch | |
import torchvision | |
import os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ray | |
@ray.remote | |
def map(start, end, boundaries): | |
vals = list(range(start, end)) | |
partitions = [] | |
prev_bound = 0 | |
for next_bound in boundaries: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ray | |
import pandas as pd | |
import numpy as np | |
import time | |
import builtins | |
from typing import Any, Generic, List, Callable, Union, Tuple, Iterable | |
import os | |
import psutil | |
import resource |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[2m[36m(MemoryMonitorActor pid=1328)[0m 148 10.8GiB /home/ray/anaconda3/lib/python3.7/site-packages/ray/core/src/ray/gcs/gcs_server --log_dir=/tmp/ray/s | |
[2m[36m(MemoryMonitorActor pid=1328)[0m 1252 1.24GiB python stress_tests/test_threaded_actors.py --test-runtime 3600 --kill-interval_s 60 | |
[2m[36m(MemoryMonitorActor pid=1328)[0m 173 0.87GiB /home/ray/anaconda3/bin/python -u /home/ray/anaconda3/lib/python3.7/site-packages/ray/dashboard/dash | |
[2m[36m(MemoryMonitorActor pid=1328)[0m 250 0.12GiB /home/ray/anaconda3/bin/python -u /home/ray/anaconda3/lib/python3.7/site-packages/ray/dashboard/agen | |
[2m[36m(MemoryMonitorActor pid=1328)[0m 64 0.09GiB /home/ray/anaconda3/bin/python /home/ray/anaconda3/bin/anyscale session web_terminal_server --deploy | |
[2m[36m(MemoryMonitorActor pid=1328)[0m 384 0.09GiB /home/ray/anaconda3/bin/python /home/ray/anaconda3/bin/anyscale session auth_start | |
[2m[36m(MemoryMonitorActor pid=1328)[0m 1328 0.06GiB ray::MemoryMonitorActor.run() | |
[2m[36m(MemoryMonitorActor pid=132 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import ray | |
import os | |
@ray.remote | |
def f(): | |
return np.random.rand(1000_000_000 // 8) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
num_nodes | nbytes | npartitions | dask_tasks | dask_nprocs | dask_nthreads | dask_memlimit | duration | |
---|---|---|---|---|---|---|---|---|
1 | 1000000000 | 100 | False | 0 | 0 | 0 | 12.28133487701416 | |
1 | 1000000000 | 100 | False | 0 | 0 | 0 | 11.294680833816528 | |
1 | 1000000000 | 100 | False | 0 | 0 | 0 | 11.143301963806152 | |
1 | 1000000000 | 100 | False | 0 | 0 | 0 | 10.956552743911743 | |
1 | 1000000000 | 100 | False | 0 | 0 | 0 | 11.068711757659912 | |
1 | 1000000000 | 100 | False | 0 | 0 | 0 | 11.079143285751343 | |
1 | 10000000000 | 100 | False | 0 | 0 | 0 | 114.72856569290161 | |
1 | 20000000000 | 100 | False | 0 | 0 | 0 | 258.343745470047 | |
1 | 100000000000 | 100 | False | 0 | 0 | 0 | 1911.8010439872742 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ray | |
import numpy as np | |
@ray.remote | |
def map(data, npartitions): | |
outputs = [list() for _ in range(npartitions)] | |
for row in data: | |
outputs[int(row * npartitions)].append(row) | |
return tuple(sorted(output) for output in outputs) |
NewerOlder