def parallel_task():
    me = ga.pgroup_nodeid()
    nproc = ga.pgroup_nnodes()
    if not me:
        print "This is process 0 on group %s" % ga.pgroup_get_default()
    g_a = ga.create(ga.C_DBL, (3,4,5))
    ga.randomize(g_a)
    if me == 0:
        print np.sum(ga.access(g_a))
Пример #2
0
def parallel_task():
    me = ga.pgroup_nodeid()
    nproc = ga.pgroup_nnodes()
    if not me:
        print "This is process 0 on group %s" % ga.pgroup_get_default()
    g_a = ga.create(ga.C_DBL, (3, 4, 5))
    ga.randomize(g_a)
    if me == 0:
        print np.sum(ga.access(g_a))
Пример #3
0
def me():
    return ga.pgroup_nodeid(ga.pgroup_get_default())
Пример #4
0
def parallel_task():
    me = ga.pgroup_nodeid()
    nproc = ga.pgroup_nnodes()
    ### print a message from the master of the group
    g_a = ga.create(ga.C_DBL, (3,4,5))
    ga.randomize(g_a)
Пример #5
0
def me():
    return ga.pgroup_nodeid(ga.pgroup_get_default())