Examine or set default cluster profile
p = parallel.defaultClusterProfile
oldprofile = parallel.defaultClusterProfile(newprofile)
p = parallel.defaultClusterProfile
returns
the name of the default cluster profile.
oldprofile = parallel.defaultClusterProfile(newprofile)
sets
the default profile to be newprofile
and returns
the previous default profile. It might be useful to keep the old profile
so that you can reset the default later.
If the default profile has been deleted, or if it has never
been set, parallel.defaultClusterProfile
returns 'local'
as
the default profile.
You can save modified profiles with the saveProfile
or saveAsProfile
method
on a cluster object. You can create, delete, import, and modify profiles
with the Cluster Profile Manager, accessible from the MATLAB desktop Home tab Environment area
by selecting Parallel > Manage Cluster Profiles.
Display the names of all available profiles and set the first in the list to be the default.
allProfiles = parallel.clusterProfiles parallel.defaultClusterProfile(allProfiles{1});
First set the profile named 'MyProfile'
to
be the default, and then set the profile named 'Profile2'
to
be the default.
parallel.defaultClusterProfile('MyProfile'); oldDefault = parallel.defaultClusterProfile('Profile2'); strcmp(oldDefault,'MyProfile') % returns true