validate
Description
validate( validates the cluster
specified by the cluster object myCluster)myCluster. You can use the
validate function to validate a cluster object after you modify a
cluster object property.
The validate function prints the validation stages performed and
an indication of whether each stage passed, failed, or was skipped.
If a validation stage fails, the function saves a validation report to the temporary folder.
validate(___, specifies
additional cluster validation options using one or more name-value arguments.Name=Value)
Examples
Create a cluster object for a remote cluster with the profile name
myMJSCluster, using the parcluster
function.
c = parcluster(myMJSCluster);
Validate the cluster object, c. The
validate function prints the validation stages performed and
an indication of whether each stage passed, failed, or was skipped.
validate(c)
Beginning cluster validation. Cluster connection test (parcluster) Stage started at 15:52:05. Using existing cluster object. ✓ Network latency: 6 ms ✓ Upload speed: 22915 KB/s ✓ Download speed: 43480 KB/s For more information on these results, see the "Troubleshooting Slow Network Connection" documentation page. Finished at 15:52:11. ......................................................PASSED Job test (createJob) Stage started at 15:52:11. Finished at 15:52:21. ......................................................PASSED SPMD job test (createCommunicatingJob) Stage started at 15:52:21. Job ran with 1 worker. Finished at 15:52:26. ......................................................PASSED Pool job test (createCommunicatingJob) Stage started at 15:52:26. Job ran with 1 worker. Finished at 15:52:45. ......................................................PASSED Parallel pool test (parpool) Stage started at 15:52:45. Connected to parallel pool with 12 workers. Parallel pool is shutting down. Parallel pool ran with 12 worker. Finished at 15:52:53. ......................................................PASSED Finished cluster validation with status: PASSED
Create a cluster object using the default cluster profile.
c = parcluster;
Validate the cluster object, c using 5 workers. Run only the
"job", "spmd-job", and
"pool-job" stages. Save the validation results to a report file
with the name "validation.txt".
validate(c,NumWorkersToUse=5, ... StagesToRun=["job","spmd-job","pool-job"],ReportFile="validation.txt")
Beginning cluster validation Cluster connection test (parcluster) Stage started at 14:46:04. Using existing cluster object. Finished at 14:46:06. ..........................................................................PASSED Job test (createJob) Stage started at 14:46:06. Finished at 14:46:52. ..........................................................................PASSED SPMD job test (createCommunicatingJob) Stage started at 14:46:55. Job ran with 5 workers. Finished at 14:47:57. ..........................................................................PASSED Pool job test (createCommunicatingJob) Stage started at 14:48:01. Job ran with 5 workers. Finished at 14:49:11. ..........................................................................PASSED Finished validation with status: PASSED Validation report written to validation.txt
Input Arguments
Cluster, specified as a parallel.Cluster object that represents
cluster compute resources. To create the parallel.Cluster object, use
the parcluster function.
Example: cluster = parcluster; validate(cluster);
Data Types: parallel.Cluster
Name-Value Arguments
Specify optional pairs of arguments as
Name1=Value1,...,NameN=ValueN, where Name is
the argument name and Value is the corresponding value.
Name-value arguments must appear after other arguments, but the order of the
pairs does not matter.
Example: NumWorkersToUse=4
Number of workers to use in validation, specified as a nonnegative integer. Use
this argument to validate the cluster object with fewer workers than those specified
in the cluster object's PreferredPoolNumWorkers or
NumWorkers property.
Example: NumWorkersToUse=4
Data Types: single | double | int8 | int16 | int32 | int64 | uint8 | uint16 | uint32 | uint64
Validation stages to run, specified as a string array or cell array of character vectors with one or more of these stage values:
"parcluster"—Cluster connection test (parcluster)stage."job"—Job test (createJob)stage."spmd-job"—SPMD job test (createCommunicatingJob)stage."pool-job"—Pool job test (createCommunicatingJob)stage."parpool"—Parallel pool test (parpool)stage."spark"—Spark job test (tall)stage."tall"—Tall evaluation test (tall gather)stage.
Some stages are only available for certain parallel environment or
cluster types. You cannot specify this argument if you specify the StagesToSkip argument. To learn more about each stage, see List of Validation Stages.
Example: StagesToRun=["job","parpool"]
Data Types: char | string | cell
Validation stages to skip, specified as a string array or cell array of character vectors with one or more of these stage values:
"parcluster"—Cluster connection test (parcluster)stage."job"—Job test (createJob)stage."spmd-job"—SPMD job test (createCommunicatingJob)stage."pool-job"—Pool job test (createCommunicatingJob)stage."parpool"—Parallel pool test (parpool)stage."spark"—Spark job test (tall)stage."tall"—Tall evaluation test (tall gather)stage.
Some stages are only available for certain parallel environment or
cluster types. You cannot specify this argument if you specify the StagesToRun argument. To learn more about each stage, see List of Validation Stages.
Example: StagesToSkip=["job","spmd-job"]
Data Types: char | string | cell
Filename to save validation report, specified as a character vector or string.
If you do not set the ReportFile argument and validation is
successful, validate does not create a report. If you do not
set the ReportFile argument and validation fails,
validate automatically creates a validation report and saves
it in the temporary folder.
Example: ReportFile="validation.txt"
Data Types: char | string
Algorithms
The validate function performs these validation stages.
| Validation Stage | Description |
|---|---|
| For remote cluster objects, tests cluster connections and displays cluster latency. |
| Tests independent job creation using the |
| Tests creation of a batch job with an SPMD enabled parallel pool using
the |
| Tests creation of a batch job with a parallel pool using the
|
| Tests creation of an interactive parallel pool using the
|
| Tests creation of a job on a Spark™ cluster. |
| Tests evaluation of a tall array on a Spark cluster using the |
Version History
Introduced in R2026a
See Also
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Web サイトの選択
Web サイトを選択すると、翻訳されたコンテンツにアクセスし、地域のイベントやサービスを確認できます。現在の位置情報に基づき、次のサイトの選択を推奨します:
また、以下のリストから Web サイトを選択することもできます。
最適なサイトパフォーマンスの取得方法
中国のサイト (中国語または英語) を選択することで、最適なサイトパフォーマンスが得られます。その他の国の MathWorks のサイトは、お客様の地域からのアクセスが最適化されていません。
南北アメリカ
- América Latina (Español)
- Canada (English)
- United States (English)
ヨーロッパ
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)