MATLAB parallel server: computation time of clustering with client and without client
3 ビュー (過去 30 日間)
I wonder that the computation time of parallel cluster with client is lower that without client.
For example, for 5 computers
Case 1: 1 client and 4 computers of cluster
Case 2: 1 client and 5 computers of cluster (including the client computer)
As the cluster includes a client computer, is the computation efficiency low?
Please, let me know.
Alison Eele 2023 年 8 月 31 日
This will likely depend heavily on the code you are intending to run and the speed of the network connection between your client machine and the cluster.
In interactive parallel workflows i.e. using parpool, the client machine will remain connected to the MATLAB Parallel Server machines and orchastrate the work you requested e.g. dividing up the iterations of a parfor or creating and retrieving parfevals.
In 'batch' workflows using something like batch() or createJob() then the client machine isn't involved beyond the point of submitting the job to the cluster.
We tend to recommend adopting a batch workflow in situations where maintaining a constant connection to the cluster is difficult, slow or not desired. In most clusters there are faster and more reliable network links between the machines of the cluster than to the outside world (especially when working with cloud resources!).
However when prototyping you may wish to use an interactive workflow to get more feedback whilst your code executes.
We don't typically expect to run the client MATLAB session on a node of the cluster but depending on your setup this may be possible.