Ask Your Question
0

Sage Cloud & Parallel processing

asked 2013-10-26 03:55:46 -0500

mresimulator gravatar image

updated 2015-01-17 10:49:52 -0500

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 06:10:48 -0500

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 03:11:10 -0500 )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-27 19:53:20 -0500 )edit

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

mresimulator gravatar imagemresimulator ( 2013-10-28 13:58:33 -0500 )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 03:55:46 -0500

Seen: 245 times

Last updated: Oct 26 '13