1

I'm trying to use something like this in matlab

parfor i = 1 : 100
    disp( sprintf('process %d\n', i) ); 
end

how do I setup the number of cores I want to use (possibly inside the script)? At this moment I always see the same (sorted) sequence.

Thank you

1 Answer 1

2

Use

matlabpool open X

where X is the number of cores you'd like to run your computation on.

Sign up to request clarification or add additional context in comments.

2 Comments

Do you know how to set ClusterSize?
To set the ClusterSize property for a configuration, you need to open the configuration editor - Parallel menu, then "Manage Configurations".

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.