Skip to content

Commit e73969a

Browse files
committed
Several minor docs edit
1 parent 64ca58e commit e73969a

File tree

7 files changed

+104
-127
lines changed

7 files changed

+104
-127
lines changed

README.md

Lines changed: 37 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Sbox
22

3-
Sbox is a toolbox for Slurm that provides information about users' accounts and jobs as well as information about the cluster resources. Sbox also can help Slurm admins to collect users' information by users ID and jobs ID. Interactive command uses Slurm `srun` and `sbatch` commands to request resources interactively including running a Jupyter server on the cluster.
3+
Sbox is a toolbox for Slurm that provides information about users' accounts and jobs as well as information about the cluster resources. Sbox also can help Slurm admins to collect users' information by user and job IDs. Interactive command uses Slurm `srun` and `sbatch` commands to request resources interactively including running a Jupyter server on the cluster.
44

55
## Commands
66

@@ -16,10 +16,10 @@ Sbox is a toolbox for Slurm that provides information about users' accounts and
1616
- `-h, --help`: Show the help message and exit.
1717
- `-a, --account`: Return user's Slurm accounts by using Slurm `sacctmgr`. If the cluster does not use Slurm for users' account management, it returns empty output.
1818
- `-f, --fairshare`: Return users' fairshare by using Slurm `sshare` command. If the cluster does not follow a fairshare model, it returns empty output.
19-
- `-g, --group`: Return user's Posix groups by using Unix `groups` command.
19+
- `-g, --group`: Return user's posix groups by using Unix `groups` command.
2020
- `-q, --queue`: Return user's jobs in the Slurm queue by Slurm using `squeue` command.
2121
- `-j, --job`: Show a running/pending job info by using Slurm `scontrol` command. It requires a valid job ID as argument.
22-
- `-c, --cpu`: Return computational resources including number of cores and amount of memory on each node. It uses Slurm `sjstat` command.
22+
- `-c, --cpu`: Return computational resources including number of cores and amount of memory on each node. It uses Slurm `sjstat` command.
2323
- `-p, --partition`: Show cluster partitions by using Slurm `sinfo` command.
2424
- `-u, --user`: Store a user ID. By default it uses `$USER` as user ID for any query that needs a user ID. It can be used with other options to find the information for other users.
2525
- `-v, --version`: Show program's version number and exit.
@@ -28,7 +28,7 @@ Sbox is a toolbox for Slurm that provides information about users' accounts and
2828
- `--pending`: Return user's pending jobs by using Slurm `squeue` command.
2929
- `--running`: Return user's running jobs by using Slurm `squeue` command.
3030
- `--qos`: Show user's quality of services (QOS) and a list of available QOS in the cluster. It uses Slurm `sacctmgr show assoc` command and return empty output if the cluster does not use Slurm for users' account management.
31-
- `--quota`: Return user's disk quotas. It uses LFS `lfs quota` command for LFS systems and Unix `df` command for NFS systems. It returns pooled size of the disk if the cluster does not have user/group storage accounts.
31+
- `--quota`: Return user's disk quotas. It uses `lfs quota` command for LFS systems and Unix `df` command for NFS systems. It returns pooled size of the disk if the cluster does not have user/group storage accounts.
3232
- `--ncpu`: Show number of available cpus on the cluster using Slurm `sinfo` command.
3333
- `--ncgu`: Show number of available gpus on the cluster using Slurm `squeue` and `sinfo` commands.
3434
- `--gpu`: Show gpu resources including gpu cards' name and numbers using Slurm `sinfo` command.
@@ -122,17 +122,17 @@ Fine jobs in the queue:
122122

123123
### Command line options
124124

125-
- `-h, --help`: Show this help message and exit
126-
- `-A, --account`: Slurm account name or project id
127-
- `-n, --ntasks`: Number of tasks (cpus)
128-
- `-N, --nodes`: Number of nodes
129-
- `-p, --partition`: Partition name
130-
- `-t, --time`: Number of hours (based on the partitions timelimit)
131-
- `-l, --license`: Add a license to an interactive session
132-
- `-m, --mem`: Amount of memory per GB
133-
- `-g, --gpu`: Number of gpus
125+
- `-h, --help`: Show this help message and exit.
126+
- `-A, --account`: Slurm account name or project id.
127+
- `-n, --ntasks`: Number of tasks (cpus).
128+
- `-N, --nodes`: Number of nodes.
129+
- `-p, --partition`: Partition name.
130+
- `-t, --time`: Number of hours based on the partitions timelimit.
131+
- `-l, --license`: Add a license to an interactive session.
132+
- `-m, --mem`: Amount of memory per GB.
133+
- `-g, --gpu`: Number of gpus.
134134
- `-k, --kernel`: Jupyter kernel for python, r, julia. The default kernel is python.
135-
- `-e, --environment`: Python environment(s) for a JupyterLab session
135+
- `-e, --environment`: Python environment(s) for a JupyterLab session.
136136

137137
**Examples**
138138

@@ -211,14 +211,14 @@ Starting Jupyter server ...
211211

212212
## Quick install
213213

214-
- Download and extract the [latest Sbox release](https://github.com/ashki23/sbox/releases/latest)
215-
- Update the `./config` file based on the cluster information. Review "Configuration" to learn more. Find a config example under `./templates/config-rcss`
216-
- To access a JupyerLab session, install Anaconda and create the required virtual environments and modulefiles. Review "Requirements" to learn more
217-
- Place a modulefile for Sbox under `$MODULEPATH/sbox` directory. As a template you may use `./templates/1.1.lua`
214+
- Download and extract the [latest Sbox release](https://github.com/ashki23/sbox/releases/latest).
215+
- Update the `./config` file based on the cluster information. Review "Configuration" to learn more.
216+
- To access a JupyerLab session, install Anaconda and create the required virtual environments and modulefiles. Review "Requirements" to learn more.
217+
- Place a modulefile for Sbox under `$MODULEPATH/sbox` directory. You can find the Sbox template modulefile in `./templates/1.2.lua`.
218218

219219
## Requirements
220220

221-
Sbox requires Slurm and Python >= 3.6.8. The `interactive jupyter` command requires Anaconda and an environment module system (e.g. [Lmod](https://lmod.readthedocs.io/en/latest/)) in addition to Slurm and Python. To use R and Julia kernels in `interactive jupyter`, we need R and irkernel as well as Julia to be installed.
221+
Sbox requires Slurm and Python >= 3.6.8. The `interactive jupyter` command requires Anaconda and an environment module system (e.g. [Lmod](https://lmod.readthedocs.io/en/latest/)) in addition to Slurm and Python. To use R and Julia in JupyterLab sessions, we need R and irkernel as well as Julia to be installed.
222222

223223
Note that Sbox options might require some other Unix commands. Review the options requirement under the command line options.
224224

@@ -239,6 +239,7 @@ To load Anaconda by `modeule load` command, create the following modeulefile un
239239

240240
```lua
241241
-- -*- lua -*-
242+
242243
whatis([[Name : anaconda]])
243244
whatis([[Version : <year.month>]])
244245
whatis([[Target : x86_64]])
@@ -259,7 +260,7 @@ prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
259260
setenv("ANACONDA_ROOT", this_root)
260261
```
261262

262-
Or the following tcl modulefile under `$MODULEPATH/anaconda/<year.month>`:
263+
Or adding the following tcl modulefile under `$MODULEPATH/anaconda/<year.month>`:
263264

264265
```tcl
265266
#%Module1.0
@@ -307,6 +308,7 @@ The following modulefile should be added to `$MODULEPATH/r-essentials/<R version
307308

308309
```lua
309310
-- -*- lua -*-
311+
310312
whatis([[Name : r-essentials]])
311313
whatis([[Version : <R version>]])
312314
whatis([[Target : x86_64]])
@@ -327,12 +329,12 @@ prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
327329
setenv("ANACONDA_ROOT", this_root)
328330
```
329331

330-
Or a tcl modulefile similar to the above tcl template for Anaconda.
332+
Or adding a tcl modulefile similar to the above tcl template for Anaconda.
331333

332334

333335
### Julia kernel
334336

335-
The `interactive jupyter -k julia` command provides Julia from a JupyterLab notebook. Julia can be installed from [Spack](https://spack.io/), [source](https://julialang.org/downloads/) or [Anaconda](https://anaconda.org/conda-forge/julia). The following shows how to install Julia from an Anaconda (Note that if Julia have been installed on the cluster, you can skip this section and use the available Julia module instead).
337+
The `interactive jupyter -k julia` command provides Julia from a JupyterLab notebook. Julia can be installed from [Spack](https://spack.io/), [source](https://julialang.org/downloads/) or [Anaconda](https://anaconda.org/conda-forge/julia). The following shows how to install Julia from Anaconda (Note that if Julia have been installed on the cluster, you can skip this section and use the available Julia module instead).
336338

337339
```bash
338340
cd /<cluster software path>/anaconda/<year.month>
@@ -346,6 +348,7 @@ The following modulefile should be added to `$MODULEPATH/julia/<version>.lua`:
346348

347349
```lua
348350
-- -*- lua -*-
351+
349352
whatis([[Name : julia]])
350353
whatis([[Version : <version>]])
351354
whatis([[Target : x86_64]])
@@ -366,9 +369,9 @@ prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
366369
setenv("ANACONDA_ROOT", this_root)
367370
```
368371

369-
Or a tcl modulefile similar to the above tcl template for Anaconda.
372+
Or adding a tcl modulefile similar to the above tcl template for Anaconda.
370373

371-
Note that the first time users run `interactive jupyter -k julia`, Julia Jupyter kernal (IJulia) will be installed under `~/.julia`.
374+
Note that the first time that users run `interactive jupyter -k julia`, Julia Jupyter kernal (IJulia) will be installed under `~/.julia`.
372375

373376
### On demand Python pakages
374377

@@ -395,6 +398,7 @@ For each env, we need to add a modulefile to `$MODULEPATH/<env name>/<version>.l
395398

396399
```lua
397400
-- -*- lua -*-
401+
398402
whatis([[Name : tensorflow]])
399403
whatis([[Version : <version>]])
400404
whatis([[Target : x86_64]])
@@ -415,7 +419,7 @@ prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
415419
setenv("ANACONDA_ROOT", this_root)
416420
```
417421

418-
Or a tcl modulefile similar to the above tcl template for Anaconda.
422+
Or adding a tcl modulefile similar to the above tcl template for Anaconda.
419423

420424

421425
## Configuration
@@ -438,14 +442,14 @@ The `sbox` and `interactive` commands are reading the required information from
438442

439443
The config file includes:
440444

441-
- `disk_quota_paths`: A list of pathes to the disk for finding users quotas. By default the first input is considered as the users' home path
442-
- `cpu_partition`: A list of computational partitions
443-
- `gpu_partition`: A list of GPU partitions
444-
- `interactive_partition_timelimit`: A dictionary of interactive partitions (i.e. users should access by `srun`) and their time limits (hour)
445-
- `jupyter_partition_timelimit`: A dictionary of computational/gpu partitions that users can run Jupter servers interactively and their time limits (hour)
446-
- `partition_qos`: A dictionary of partitions and the corresponding quality of services
447-
- `kernel_module`: A dictionary of kernels and the corresponding modules
448-
- `env_module`: A dictionary of Python virtual environments and the corresponding modules
445+
- `disk_quota_paths`: A list of paths to the disk for finding users quotas. By default the first input is considered as the users' home path.
446+
- `cpu_partition`: A list of computational partitions.
447+
- `gpu_partition`: A list of GPU partitions.
448+
- `interactive_partition_timelimit`: A dictionary of interactive partitions (i.e. users should access by `srun`) and their time limits (hour). The first input is considered as the default partition.
449+
- `jupyter_partition_timelimit`: A dictionary of computational/gpu partitions that users can run Jupter servers interactively and their time limits (hour). The first input is considered as the default partition.
450+
- `partition_qos`: A dictionary of partitions and the corresponding quality of services.
451+
- `kernel_module`: A dictionary of kernels and the corresponding modules. A Python kernel is required (review the Requirments).
452+
- `env_module`: A dictionary of Python virtual environments and the corresponding modules.
449453

450454
For example:
451455

docs/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Sbox
22
====
33

4-
Sbox is a toolbox for Slurm that provides information about users' accounts and jobs as well as information about the cluster resources. Sbox also can help Slurm admins to collect users' information by users ID and jobs ID. Interactive command uses Slurm ``srun`` and ``sbatch`` commands to request resources interactively including running a Jupyter server on the cluster.
4+
Sbox is a toolbox for Slurm that provides information about users' accounts and jobs as well as information about the cluster resources. Sbox also can help Slurm admins to collect users' information by user and job IDs. Interactive command uses Slurm ``srun`` and ``sbatch`` commands to request resources interactively including running a Jupyter server on the cluster.
55

66
.. note:: You can download the latest release of Sbox from `https://github.com/ashki23/sbox/releases/latest <https://github.com/ashki23/sbox/releases/latest>`_ and find the codes or fork the repository on `https://github.com/ashki23/sbox <https://github.com/ashki23/sbox>`__.
77

docs/requirements.rst

Lines changed: 26 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,20 @@
11
Quick install
22
=============
33

4-
- Download and extract the `latest Sbox release <https://github.com/ashki23/sbox/releases/latest>`__
4+
- Download and extract the `latest Sbox release <https://github.com/ashki23/sbox/releases/latest>`__.
55
- Update the ``./config`` file based on the cluster information. Review
6-
`“Configuration” <https://sbox.readthedocs.io/en/latest/requirements.html#configuration>`__ to learn more. Find a config example under
7-
``./templates/config-rcss``
8-
- To access a JupyerLab session, install Anaconda and create
9-
the required virtual environments and modulefiles. Review
10-
`“Requirements” <https://sbox.readthedocs.io/en/latest/requirements.html#requirements>`__ to learn more.
11-
- Place a modulefile for Sbox under ``$MODULEPATH/sbox`` directory. As
12-
a template you may use ``./templates/1.1.lua``
6+
`Configuration <https://sbox.readthedocs.io/en/latest/requirements.html#configuration>`__ to learn more.
7+
- To access a JupyerLab session, install Anaconda and create the required virtual environments and modulefiles. Review
8+
`Requirements <https://sbox.readthedocs.io/en/latest/requirements.html#requirements>`__ to learn more.
9+
- Place a modulefile for Sbox under ``$MODULEPATH/sbox``. You can find the Sbox template modulefile in `here <https://github.com/ashki23/sbox/blob/main/templates/1.2.lua>`__.
1310

1411
Requirements
1512
============
1613

1714
Sbox requires Slurm and Python >= 3.6.8. The ``interactive jupyter``
1815
command requires Anaconda and an environment module system
1916
(e.g. `Lmod <https://lmod.readthedocs.io/en/latest/>`__) in addition to
20-
Slurm and Python. To use R and Julia kernels in ``interactive jupyter``,
21-
we need R and irkernel as well as Julia to be installed.
17+
Slurm and Python. To use R and Julia in JupyterLab sessions, we need R and irkernel as well as Julia to be installed.
2218

2319
Note that Sbox options might require some other Unix commands. Review
2420
the options requirement under the `command line options <https://sbox.readthedocs.io/en/latest/sbox.html#command-line-options>`__.
@@ -49,6 +45,7 @@ modeulefile under ``$MODULEPATH/anaconda/<year.month>.lua``:
4945
.. code:: lua
5046
5147
-- -*- lua -*-
48+
5249
whatis([[Name : anaconda]])
5350
whatis([[Version : <year.month>]])
5451
whatis([[Target : x86_64]])
@@ -68,7 +65,7 @@ modeulefile under ``$MODULEPATH/anaconda/<year.month>.lua``:
6865
prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
6966
setenv("ANACONDA_ROOT", this_root)
7067
71-
Or the following tcl modulefile under
68+
Or adding the following tcl modulefile under
7269
``$MODULEPATH/anaconda/<year.month>``:
7370

7471
.. code::
@@ -127,6 +124,7 @@ env:
127124
.. code:: lua
128125
129126
-- -*- lua -*-
127+
130128
whatis([[Name : r-essentials]])
131129
whatis([[Version : <R version>]])
132130
whatis([[Target : x86_64]])
@@ -146,7 +144,7 @@ env:
146144
prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
147145
setenv("RESSENTIALS_ROOT", this_root)
148146
149-
Or a tcl modulefile similar to the above tcl template for Anaconda.
147+
Or adding a tcl modulefile similar to the above tcl template for Anaconda.
150148

151149
Julia kernel
152150
------------
@@ -156,7 +154,7 @@ JupyterLab notebook. Julia can be installed from
156154
`Spack <https://spack.io/>`__,
157155
`source <https://julialang.org/downloads/>`__ or
158156
`Anaconda <https://anaconda.org/conda-forge/julia>`__. The following
159-
shows how to install Julia from an Anaconda (Note that if Julia have
157+
shows how to install Julia from Anaconda (Note that if Julia have
160158
been installed on the cluster, you can skip this section and use the
161159
available Julia module instead).
162160

@@ -175,6 +173,7 @@ The following modulefile should be added to
175173
.. code:: lua
176174
177175
-- -*- lua -*-
176+
178177
whatis([[Name : julia]])
179178
whatis([[Version : <version>]])
180179
whatis([[Target : x86_64]])
@@ -194,9 +193,9 @@ The following modulefile should be added to
194193
prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
195194
setenv("JULIA_ROOT", this_root)
196195
197-
Or a tcl modulefile similar to the above tcl template for Anaconda.
196+
Or adding a tcl modulefile similar to the above tcl template for Anaconda.
198197

199-
Note that the first time users run ``interactive jupyter -k julia``,
198+
Note that the first time that users run ``interactive jupyter -k julia``,
200199
Julia Jupyter kernal (IJulia) will be installed under ``~/.julia``.
201200

202201
On demand Python pakages
@@ -231,6 +230,7 @@ For each env, we need to add a modulefile to
231230
.. code:: lua
232231
233232
-- -*- lua -*-
233+
234234
whatis([[Name : tensorflow]])
235235
whatis([[Version : <version>]])
236236
whatis([[Target : x86_64]])
@@ -250,7 +250,7 @@ For each env, we need to add a modulefile to
250250
prepend_path("PKG_CONFIG_PATH", this_root .. "/lib/pkgconfig", ":")
251251
setenv("TENSORFLOW_ROOT", this_root)
252252
253-
Or a tcl modulefile similar to the above tcl template for Anaconda.
253+
Or adding a tcl modulefile similar to the above tcl template for Anaconda.
254254

255255
configuration
256256
=============
@@ -274,23 +274,21 @@ information from the below JSON config file.
274274
275275
The config file includes:
276276

277-
- ``disk_quota_paths``: A list of pathes to the disk for finding users
278-
quotas. By default the first input is considered as the users’ home
279-
path
280-
- ``cpu_partition``: A list of computational partitions
281-
- ``gpu_partition``: A list of GPU partitions
277+
- ``disk_quota_paths``: A list of paths to the disks for finding users
278+
quotas. By default the first input is considered as the users’ home path.
279+
- ``cpu_partition``: A list of computational partitions.
280+
- ``gpu_partition``: A list of GPU partitions.
282281
- ``interactive_partition_timelimit``: A dictionary of interactive
283282
partitions (i.e. users should access by ``srun``) and their time
284-
limits (hour)
283+
limits (hour). The first input is considered as the default partition.
285284
- ``jupyter_partition_timelimit``: A dictionary of computational/gpu
286285
partitions that users can run Jupter servers interactively and their
287-
time limits (hour)
286+
time limits (hour). The first input is considered as the default partition.
288287
- ``partition_qos``: A dictionary of partitions and the corresponding
289-
quality of services
290-
- ``kernel_module``: A dictionary of kernels and the corresponding
291-
modules
292-
- ``env_module``: A dictionary of Python virtual environments and the
293-
corresponding modules
288+
quality of services.
289+
- ``kernel_module``: A dictionary of kernels and the corresponding modules.
290+
A Python kernel is required (review `here <https://sbox.readthedocs.io/en/latest/requirements.html#python-kernel-anaconda>`__).
291+
- ``env_module``: A dictionary of Python virtual environments and the corresponding modules.
294292

295293
For example:
296294

0 commit comments

Comments
 (0)