Ask Your Question
0

Sage Cloud & Parallel processing

asked 2013-10-26 10:55:46 +0100

mresimulator gravatar image

updated 2015-01-17 17:49:52 +0100

FrédéricC gravatar image

Hi experts!

I wanna use multiprocessing using 288 cores of SageCloud for my Monte Carlo algorithm. Is that possible?

My algorithm is like this:

import numpy as np
experiments=1000
sticks= np.array(range(1,1000,1))

def function_1():
    funciton_1...

def function_2():
    funciton_2...

for n in sticks:
    for u range(experiments):
        algorithm is executed and a number 'jjjj' is geretaed and saved in array 'numbers jjjj'.
    all values in array 'numbers jjjj' are averaged and saved in array 'numbers for each stick'

the array 'numpers for each stick' is saved as .cvs

In the possitive case: I dont know how to incorporate @parallel decorator in my script.

Please help!

Thanks a lot

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
2

answered 2013-10-26 13:10:48 +0100

William Stein gravatar image

I wanna use multiprocessing using 288 cores of SageCloud for my Monte Carlo algorithm. Is that possible?

Unfortunately not at present. The 288 cores refers to the total number of CPU cores across all 19 machines in the cluster(s). When you create a project, it has access to only 12 cores. The main thing that "288 cores" brings is the ability of the cluster to scale up to a large number of simultaneous users. I.e., it's safe to encourage everybody you know to use https://cloud.sagemath.com.

At some point in the future, the answer to this question will be: "pay $10" to get n dedicated cores for the next k hours, or something like that. But that's just not setup yet.

edit flag offensive delete link more

Comments

Thanks William. 12 cores is enought. How can I use @parallel decorator to my own script? Waiting for your answer. Thanks a lot!

mresimulator gravatar imagemresimulator ( 2013-10-27 09:11:10 +0100 )edit

Can you make your exact code more precise? I.e., finish writing it in a single-core way? Then, email me (wstein@uw.edu).

William Stein gravatar imageWilliam Stein ( 2013-10-28 01:53:20 +0100 )edit

I send you my script by e-mail. Waiting for your answer. Thanks a lot!

mresimulator gravatar imagemresimulator ( 2013-10-28 19:58:33 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2013-10-26 10:55:46 +0100

Seen: 649 times

Last updated: Oct 26 '13