Skip to content

Commit

Permalink
trigger reformat
Browse files Browse the repository at this point in the history
  • Loading branch information
rjzamora committed Mar 4, 2021
1 parent c5a172d commit ecc0c85
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions dask_cuda/benchmarks/local_cudf_merge.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,17 +140,10 @@ def merge(args, ddf1, ddf2, write_profile):
# "--shuffle-join" or "--broadcast-join" was
# specified (with "--shuffle-join" taking
# precedence)
broadcast = False if args.shuffle_join else (
True if args.broadcast_join else None
)
broadcast = False if args.shuffle_join else (True if args.broadcast_join else None)

# Lazy merge/join operation
ddf_join = ddf1.merge(
ddf2,
on=["key"],
how="inner",
broadcast=broadcast,
)
ddf_join = ddf1.merge(ddf2, on=["key"], how="inner", broadcast=broadcast,)
if args.set_index:
ddf_join = ddf_join.set_index("key")

Expand Down Expand Up @@ -241,6 +234,9 @@ def main(args):
scheduler_workers = client.run_on_scheduler(get_scheduler_workers)
n_workers = len(scheduler_workers)
client.wait_for_workers(n_workers)

# Allow the number of chunks to vary between
# the "base" and "other" DataFrames
args.base_chunks = args.base_chunks or n_workers
args.other_chunks = args.other_chunks or n_workers

Expand Down Expand Up @@ -274,8 +270,8 @@ def main(args):
for (w1, w2), nb in total_nbytes.items()
}

broadcast = "false" if args.shuffle_join else (
"true" if args.broadcast_join else "default"
broadcast = (
"false" if args.shuffle_join else ("true" if args.broadcast_join else "default")
)

t_runs = numpy.empty(len(took_list))
Expand Down

0 comments on commit ecc0c85

Please sign in to comment.