From b62d58a31d5ec94197da5d050f66cbc8daf4580d Mon Sep 17 00:00:00 2001
From: "Peter W. Draper" <p.w.draper@durham.ac.uk>
Date: Wed, 16 Dec 2015 15:02:29 +0000
Subject: [PATCH] Gather into threads first not ranks

---
 examples/plot_tasks_MPI.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/plot_tasks_MPI.py b/examples/plot_tasks_MPI.py
index 612b79fc05..5e2f24a0bf 100644
--- a/examples/plot_tasks_MPI.py
+++ b/examples/plot_tasks_MPI.py
@@ -122,7 +122,7 @@ for line in range(num_lines):
     if tic > 0 and toc > 0:
         rank = int(data[line,0])
         thread = int(data[line,1])
-        index = thread*nranks + rank
+        index = rank*nranks + thread
         tasks[index].append({})
         tasks[index][-1]["type"] = types[ str(int(data[line,2])) ]
         tasks[index][-1]["subtype"] = subtypes[str(int(data[line,3]))]
-- 
GitLab