Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
VinceDayrit-initial_RESIT_project-/#Parallel Processing Code.py
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
17 lines (13 sloc)
390 Bytes
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
#Parallel Processing Code = | |
from dask.distributed import Client | |
import time | |
n_processors = [10, 20] | |
n_processors_time = {} | |
for processor in n_processors: | |
client = Client(n_workers=processor) | |
start = time.time() | |
#Data analysis tasks = | |
dask_time = time.time() - start | |
n_processors_time[processor] = dask_time | |
client.close() | |
print(n_processors_time) |