ValueStore and FileStore objects: Retrieve data
and files on MATLAB clients during job execution
ValueStore (Parallel Computing Toolbox) and
FileStore (Parallel Computing Toolbox)
objects now allow you to store data and files from MATLAB® workers that can be retrieved by MATLAB clients during the execution of a job (even while the job is still running).
These objects are not held in system memory, so they can be used to store large results. A
FileStore object provides a universal location for workers to copy
files. MATLAB clients can then access these files regardless of the specific cluster
environment where the worker is running.
The ValueStore and FileStore objects are
automatically created when you create a job on a cluster, a parallel pool of process workers
on your local machine, or a parallel pool of workers on a cluster of machines. To access the
ValueStore and FileStore objects on a worker, use
the getCurrentValueStore (Parallel Computing Toolbox) and getCurrentFileStore (Parallel Computing Toolbox) functions, respectively.
Multifactor Authentication for the Generic Scheduler Interface: Connect to remote
clients with RemoteClusterAccess using two or more authentication
factors
RemoteClusterAccess (Parallel Computing Toolbox) objects now allow you to
perform multifactor authentication, including two-factor authentication. To do so, specify
'Multifactor' for the AuthenticationMode name-value
argument. For details, see the RemoteClusterAccess reference page. The
sample plugin scripts for third-party schedulers now accept 'Multifactor'
as the value for the AuthenticationMode property of
AdditionalProperties, which sets that value on
RemoteClusterAccess.
Cluster resizing: Customize your MATLAB Job Scheduler cluster to resize automatically
You can customize your MATLAB Job Scheduler (MJS) cluster to resize automatically. After you set up auto-resizing, also called auto-scaling, the cluster can automatically change the number of workers with the amount of work submitted. The cluster grows (scales up) when there is more work to do and shrinks (scales down) when there is less work to do. This allows you to use your compute resources more efficiently and can result in cost savings. To learn more, see Set up MATLAB Job Scheduler Cluster for Auto-Resizing.
Parallel Pools: Check status of pools
Starting in R2022a, you can query if any type of pool is currently running by using the
Busy property of the pool. This property indicates whether the parallel
pool is busy, specified as true or false. The pool is
busy if there is outstanding work for the pool to complete.
Background Pool: Number of thread workers no longer limited to 8 workers
Before R2022a, the NumWorkers property was capped at a maximum of 8
workers when Parallel Computing Toolbox™ was installed, and 1 worker when not installed. This limit is no longer in
place when the Parallel Computing Toolbox is installed. When Parallel Computing Toolbox is not installed, the background pool remains limited to 1 worker.
Thread-Based Parallel Pool: See futures in active pool
Starting in R2022a, you can query all queued and running futures on a parallel pool by
using the FevalQueue property of the pool. To create futures, use
parfeval (Parallel Computing Toolbox) and parfevalOnAll (Parallel Computing Toolbox). For more information on futures, see Future (MATLAB).
cancelAll Method: Cancel currently queued and running futures in a
parallel pool
cancelAll (Parallel Computing Toolbox)
cancels all futures currently queued or running in a parallel pool. Queued or running
futures are listed in the FevalQueue property.
For example, you can use cancelAll to stop all
Futures in an FevalQueue.
pool = parpool; cancelAll(pool.FevalQueue);
GPU Functionality: Use new and enhanced gpuArray functions
New GPU support in MATLAB:
besselj (MATLAB), bessely (MATLAB) — Support for scale input argument
deconv (MATLAB)
eps (MATLAB), flintmax (MATLAB), intmax (MATLAB), intmin (MATLAB), realmax (MATLAB), realmin (MATLAB) — Support for "like" syntax to return scalars
from prototype object
filter (MATLAB) — Support for all syntaxes and
any vector sizes of the numerator and denominator coefficients of a rational transfer
function in the input arguments
pagefun (Parallel Computing Toolbox) — Support for conv2 (MATLAB), qr (MATLAB), and svd (MATLAB)
pageinv (MATLAB)
pagesvd (MATLAB)
svd (MATLAB)
For more information, see Run MATLAB Functions on a GPU (Parallel Computing Toolbox).
New GPU support in Statistics and Machine Learning Toolbox™:
fitensemble (Statistics and Machine Learning Toolbox)
fitrensemble (Statistics and Machine Learning Toolbox)
New support for probability functions: gev*,
gp*, nbin*
For a list of all Statistics and Machine Learning Toolbox functions with GPU functionality, see Functions with gpuArray
support (Statistics and Machine Learning Toolbox).
The following functions have new and enhanced gpuArray support in
Signal Processing Toolbox™:
For a list of all Signal Processing Toolbox functions with GPU functionality, see Functions with gpuArray
support (Signal Processing Toolbox).
The following functions have new gpuArray support in Audio Toolbox™:
pitch (Audio Toolbox)
audioDataAugmenter (Audio Toolbox)
audioFeatureExtractor (Audio Toolbox) - improved support
For a list of all Audio Toolbox functions with GPU functionality, see Functions with gpuArray
support (Audio Toolbox).
The following functions have new gpuArray and dlArray
support in Wavelet Toolbox™:
For a list of all Wavelet Toolbox functions with GPU functionality, see Functions with gpuArray
support (Wavelet Toolbox).
Support for NVIDIA
CUDA
11.2: Update to CUDA Toolkit 11.2
The parallel computing products now use CUDA® toolkit version 11.2. To generate CUDA kernel objects from CU code or compile CUDA compatible source code, libraries, and executables using GPU Coder™, you must use toolkit version 11.2. For more information,
see Run CUDA or PTX Code on GPU (Parallel Computing Toolbox).
Distributed Arrays: Use new and enhanced distributed array functionality
deconv (MATLAB)
eps (MATLAB), flintmax (MATLAB), intmax (MATLAB), intmin (MATLAB), realmax (MATLAB), realmin (MATLAB) — Support for "like" syntax to return scalars
from prototype object
movmad (MATLAB), movmax (MATLAB), movmean (MATLAB), movmedian (MATLAB), movmin (MATLAB), movprod (MATLAB), movstd (MATLAB), movsum (MATLAB), movvar (MATLAB)
For more information, see Run MATLAB Functions with Distributed Arrays (Parallel Computing Toolbox).
Parallel Features in Other Products
Parallel features added in other products:
Experiment Manager: Offload deep learning experiments as batch jobs in a cluster
Starting in R2022a, Experiment Manager (Deep Learning Toolbox) supports offloading experiments as batch jobs in a cluster. You can configure the cluster to run multiple trials at the same time or to run a single trial at a time on multiple parallel workers. While the experiment is running in the cluster, you can run other experiments, close the app and continue using MATLAB, or close your MATLAB session. For more information, see Offload Experiments as Batch Jobs to Cluster (Deep Learning Toolbox).
Parallel Simulations: Perform parameter sweeps using Parameter Combinations
In R2022a, you can use Parameter Combinations in the Multiple Simulations panel of the Simulink® Editor for workflows with multiple simulations, such as Monte-Carlo simulations and parameter sweeps. Parameter Combinations allows you to create sequential and exhaustive combinations of parameters, specify value ranges, and run simulations with these combinations. The Multiple Simulations panel was introduced in R2021b.
Machine Learning Apps: Train draft models in parallel or train in the background to keep the app responsive
In Classification Learner (Statistics and Machine Learning Toolbox) and Regression Learner (Statistics and Machine Learning Toolbox), you can train multiple draft models in parallel. You can use the Use Parallel or Use Background buttons while training models.
Solving Linear System: Improved performance when solving linear systems A*X =
B with gpuArray for symmetric positive definite matrices
A
Solving a linear system of the form A*X = B with
gpuArray by executing A\B shows improved performance
when A is a symmetric positive definite matrix.
For example, this code solves A*X = B for a 10,000-by-10,000
symmetric positive definite matrix A and a 10,000-by-1 column vector
B. The code is about 2.4x faster than in the previous release.
function timingTest rng default R = rand(10000,"gpuArray"); A = R'*R; B = ones(10000,1,"gpuArray"); X = A\B; end
The approximate execution times are:
R2021b: 1.03 s
R2022a: 0.43 s
The code was timed on a Windows® 10, Intel®
Xeon® CPU E5-1640 v3 @ 3.50 GHz with an NVIDIA® Titan V GPU test system using the gputimeit
function:
gputimeit(@timingTest)
Functionality being removed or changed
Support for macOS has been removed
Errors
Support for macOS has been removed in R2022a. To run the MATLAB Parallel Server™ cluster, use a Windows or Linux® operating system instead.
You can still connect to a MATLAB Parallel Server cluster when you use Parallel Computing Toolbox running on a macOS client.
distcomp folder removed, now named
parallel
The distcomp folder has been removed.
In R2019b, the Parallel Computing Toolbox folder was renamed. Since then, the name of the toolbox folder has been
parallel. If you need to reference the location of the toolbox,
update your references to use toolbox/parallel instead of
toolbox/distcomp.