Skip to content

Commit

Permalink
Adding profiling to dask shuffle
Browse files Browse the repository at this point in the history
  • Loading branch information
arunraman committed May 25, 2021
1 parent ab1d35c commit 5db9477
Showing 1 changed file with 19 additions and 9 deletions.
28 changes: 19 additions & 9 deletions dask_cuda/benchmarks/local_cudf_shuffle.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,24 @@ def shuffle_dask(args, df, write_profile):
return clock() - t1


def shuffle_explicit_comms(args, df):
t1 = clock()
wait(
dask_cuda.explicit_comms.dataframe.shuffle.shuffle(
df, column_names="data"
).persist()
)
took = clock() - t1
def shuffle_explicit_comms(args, df, write_profile):
if write_profile is not None:
with performance_report(filename=args.profile):
t1 = clock()
wait(
dask_cuda.explicit_comms.dataframe.shuffle.shuffle(
df, column_names="data"
).persist()
)
took = clock() - t1
else:
t1 = clock()
wait(
dask_cuda.explicit_comms.dataframe.shuffle.shuffle(
df, column_names="data"
).persist()
)
took = clock() - t1
return took


Expand All @@ -66,7 +76,7 @@ def run(client, args, n_workers, write_profile=None):
if args.backend == "dask":
took = shuffle_dask(args, df, write_profile)
else:
took = shuffle_explicit_comms(args, df)
took = shuffle_explicit_comms(args, df, write_profile)

return (data_processed, took)

Expand Down

0 comments on commit 5db9477

Please sign in to comment.