From 2380cb9b31cbbc15554749f740bd38652415a50b Mon Sep 17 00:00:00 2001 From: "weihong.xu" Date: Sun, 26 Nov 2023 20:06:00 +0800 Subject: [PATCH] fix format --- doc/manual/batch.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/manual/batch.md b/doc/manual/batch.md index 0d23fd69..72f56f71 100644 --- a/doc/manual/batch.md +++ b/doc/manual/batch.md @@ -20,14 +20,14 @@ ai2-kit tool batch gen_batches --help Suppose you want to run new CP2K tasks based on the previous runs, whose work directories can be found with `./old/iters*/label-cp2k/tasks/*`, and the new CP2K config file is in `./new/cp2k.inp`, then you can do the following steps: -1. Create new tasks directories by linking to (or copying) the old ones +#### 1. Create new tasks directories by linking to (or copying) the old ones ```bash ai2-kit tool batch map_path ./old/iters*/label-cp2k/tasks/* --target "new/task-{i:04d}" ``` The command above will create new directories `new/task-0000`, `new/task-0001`, etc. and link the old tasks directories to them. If you want to copy the old tasks directories instead of linking them, you can use `--copy` option. -2. Generate batch scripts +#### 2. Generate batch scripts Suppose you are using SLURM as your job scheduler, then you need to prepare a header file for your batch scripts. For example, you can create a file named `header.sh` with the following content: @@ -52,7 +52,7 @@ ai2-kit tool batch gen_batches new/task-* --header_file header.sh --cmd "mpirun The above command will generate 5 batch scripts named `new/cp2k-0.sbatch`, `new/cp2k-1.sbatch`, etc. and each batch script will run part of the tasks in `new/task-*` directory. -3. Submit batch scripts to your job scheduler +#### 3. Submit batch scripts to your job scheduler You can submit the batch scripts to your job scheduler with `sbatch` and `xargs` commands. ```bash ls -1 new/cp2k-*.sbatch | xargs -I {} sbatch {}