EDITORIAL
Laboratory studies have a long overdue, late last year I was given to do the finishing work. The study is the experiment code using MATLAB, have been around January is almost changing for the better code logic, but not enough time to get verification on large data sets. Unfortunately crown hit a new outbreak of pneumonia, had returned to work in February can be carried out in the laboratory have to complete at home. But the server intelligent laboratory in the laboratory LAN connection range, Tencent cloud, AWS like a cloud server either does not support MATLAB, or toll pit father, then had to look for other ways.
Fortunately, after communicated with the teacher, I was pleasantly surprised to find school there Supercomputer Center is such a good resource, but also pleasantly surprised to get the account number and password from the sister school there ...... but things are not always so smooth, Supercomputer Center official website documentation on the organization was chaotic, so as I stepped on a lot of white pit, so to write this blog a note of Wuhan University Supercomputer correct and easy to use steps.
Start of Text
Account Application
Also mentioned above, I use the teacher's account is ready ...... this part of the time being skipped go QAQ
Upload project resources
Use sftp client (such as Xmanager, SSH Secure Shell Client etc. comes with its own file transfer capabilities, or use FileZilla, WinScp, FlashFTP like sftp data transfer software) to log in 202.114.96.177
(through off-campus access requires VPN).
After a successful login will display three links, the project
incoming data partition, this partition large capacity and fast read speed, scripts, and data should be required to run uploaded to this partition.
Scripting
Ultra-count command to submit jobs, there are two, srun
and sbatch
the former need to run for command line interaction, which need to hang suited to run the program running in the background. MATLAB to perform the task for large-scale data operations, the easiest way is to write a MATLAB script can perform all the steps, and then put it into Linux scripts to perform the following format:
#!/bin/bash
module load matlab/R2018b
matlab -nosplash -nodesktop -r test_robot
Where the first line with "#!" Character at the beginning, and to develop interpreter script file;
the second line to load the operating environment, refer to MATLAB specific version number of the /software/MATLAB/
contents of the selection, here is R2018b;
line 3 is common command line to run MATLAB script commands.
Finally, the above script saved in text format in the project
retained partition, bringing the end of the preparatory work has been completed sftp.
submit homework
Use ssh client (such as Xmanager, Putty, SecureCRT, SSH Secure Shell Client) to login swarm.whu.edu.cn
(via off-campus access requires VPN).
Followed by the implementation cd project/[脚本所在目录]
and sbatch [选项] [脚本名]
to submit jobs to run in the background.
Then you can squeue
view the job execution status command, you can exit the terminal to do other things.
View Results
Log back sftp client, submitted the name will appear in the directory before Linux script slurm-[任务号].out
file, where they record all output MATLAB execution. As for the other output, such as .mat
data format, it is entirely consistent with the way the output on a normal server.