Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
Berzelius Benchmarks
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Xuan Gu
Berzelius Benchmarks
Commits
dace0691
Commit
dace0691
authored
1 year ago
by
Xuan Gu
Browse files
Options
Downloads
Patches
Plain Diff
Update 2 files
- /scripts/benchmark_sbatch_submit.sh - /scripts/benchmark_multi_node.sbatch
parent
d7617681
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
scripts/benchmark_multi_node.sbatch
+11
-7
11 additions, 7 deletions
scripts/benchmark_multi_node.sbatch
scripts/benchmark_sbatch_submit.sh
+9
-13
9 additions, 13 deletions
scripts/benchmark_sbatch_submit.sh
with
20 additions
and
20 deletions
scripts/benchmark_multi_node.sbatch
+
11
−
7
View file @
dace0691
#!/bin/bash
sbatch
<<
EOT
#!/bin/bash
#SBATCH -A nsc
#SBATCH --nodes=
8
#SBATCH --nodes=
${
2
}
#SBATCH --gres=gpu:8
#SBATCH --ntasks-per-node=8
#SBATCH --time=0-00:10:00
#####SBATCH --reservation=bt-xuan_2nodes
# For singularity
rm
-f
results/benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_tf32_iteration
${
5
}
.json
srun singularity
exec
--nv
-B
${
PWD
}
/data:/data
-B
${
PWD
}
/results:/results nvidia_nnu-net_for_pytorch.sif bash
-c
"cd /workspace/nnunet_pyt && python scripts/benchmark.py --mode train --gpus
${
3
}
--dim
${
1
}
--batch_size
${
4
}
--nodes
${
2
}
--logname="
benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_tf32_iteration
${
5
}
.json
""
#
rm -f results/benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_tf32_iteration
${
5
}
.json
#
srun singularity exec --nv -B
${
PWD
}
/data:/data -B
${
PWD
}
/results:/results nvidia_nnu-net_for_pytorch.sif bash -c "cd /workspace/nnunet_pyt && python scripts/benchmark.py --mode train --gpus
${
3
}
--dim
${
1
}
--batch_size
${
4
}
--nodes
${
2
}
--logname="benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_tf32_iteration
${
5
}
.json""
#rm -f results/benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_amp_iteration
${
5
}
.json
#srun singularity exec --nv -B
${
PWD
}
/data:/data -B
${
PWD
}
/results:/results nvidia_nnu-net_for_pytorch.sif bash -c "cd /workspace/nnunet_pyt && python scripts/benchmark.py --mode train --gpus
${
3
}
--dim
${
1
}
--batch_size
${
4
}
--nodes
${
2
}
--amp --logname="benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_amp_iteration
${
5
}
.json""
...
...
@@ -24,9 +27,10 @@ srun singularity exec --nv -B ${PWD}/data:/data -B ${PWD}/results:/results nvidi
############## Running srun with pyxis works
# For enroot
#
rm -f results/benchmark_dim${1}_nodes${2}_gpus${3}_batchsize${4}_tf32_iteration${5}.json
#
srun --container-image=/proj/nsc_testing/xuan/enroot/xuagu37+nvidia_nnu-net_for_pytorch+21.11.0.sqsh --container-name=nnunet --container-mounts=${PWD}/data:/data,${PWD}/results:/results --container-writable bash -c "cd /workspace/nnunet_pyt && python scripts/benchmark.py --mode train --gpus ${3} --dim ${1} --batch_size ${4} --nodes ${2} --logname="benchmark_dim${1}_nodes${2}_gpus${3}_batchsize${4}_tf32_iteration${5}.json""
rm -f results/benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_tf32_iteration
${
5
}
.json
srun --container-image=/proj/nsc_testing/xuan/enroot/xuagu37+nvidia_nnu-net_for_pytorch+21.11.0.sqsh --container-name=nnunet --container-mounts=
${
PWD
}
/data:/data,
${
PWD
}
/results:/results --container-writable bash -c "cd /workspace/nnunet_pyt && python scripts/benchmark.py --mode train --gpus
${
3
}
--dim
${
1
}
--batch_size
${
4
}
--nodes
${
2
}
--logname="benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_tf32_iteration
${
5
}
.json""
#
rm -f results/benchmark_dim${1}_nodes${2}_gpus${3}_batchsize${4}_amp_iteration${5}.json
#
srun --container-image=/proj/nsc_testing/xuan/enroot/xuagu37+nvidia_nnu-net_for_pytorch+21.11.0.sqsh --container-name=nnunet --container-mounts=${PWD}/data:/data,${PWD}/results:/results --container-writable bash -c "cd /workspace/nnunet_pyt && python scripts/benchmark.py --mode train --gpus ${3} --dim ${1} --batch_size ${4} --nodes ${2} --amp --logname="benchmark_dim${1}_nodes${2}_gpus${3}_batchsize${4}_amp_iteration${5}.json""
rm -f results/benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_amp_iteration
${
5
}
.json
srun --container-image=/proj/nsc_testing/xuan/enroot/xuagu37+nvidia_nnu-net_for_pytorch+21.11.0.sqsh --container-name=nnunet --container-mounts=
${
PWD
}
/data:/data,
${
PWD
}
/results:/results --container-writable bash -c "cd /workspace/nnunet_pyt && python scripts/benchmark.py --mode train --gpus
${
3
}
--dim
${
1
}
--batch_size
${
4
}
--nodes
${
2
}
--amp --logname="benchmark_dim
${
1
}
_nodes
${
2
}
_gpus
${
3
}
_batchsize
${
4
}
_amp_iteration
${
5
}
.json""
EOT
\ No newline at end of file
This diff is collapsed.
Click to expand it.
scripts/benchmark_sbatch_submit.sh
+
9
−
13
View file @
dace0691
...
...
@@ -17,21 +17,17 @@ for gpus in {1..8}; do
done
done
for
nodes
in
{
2..8
}
for
gpus
in
{
8
}
;
do
for
batch_size
in
128
;
do
for
iteration
in
{
1..100
}
;
do
for
nodes
in
{
2..8
}
;
do
for
gpus
in
{
8
}
;
do
for
batch_size
in
128
;
do
for
iteration
in
{
1..100
}
;
do
echo
dim
${
dim
}
, nodes
${
nodes
}
, gpus
${
gpus
}
, batch_size
${
batch_size
}
, iteration
${
iteration
}
# For single node
sbatch
-o
sbatch_out/benchmark_dim
${
dim
}
_nodes
${
nodes
}
_gpus
${
gpus
}
_batchsize
${
batch_size
}
_iteration
${
iteration
}
.out benchmark_single_node.sbatch
${
dim
}
${
nodes
}
${
gpus
}
${
batch_size
}
${
iteration
}
# For multi node
#sbatch -o sbatch_out/benchmark_dim${dim}_nodes${nodes}_gpus${gpus}_batchsize${batch_size}_iteration${iteration}.out benchmark_multi_node.sbatch ${dim} ${nodes} ${gpus} ${batch_size} ${iteration}
sleep
1
# pause to be kind to the scheduler
# For multi node
sbatch
-o
sbatch_out/benchmark_dim
${
dim
}
_nodes
${
nodes
}
_gpus
${
gpus
}
_batchsize
${
batch_size
}
_iteration
${
iteration
}
.out benchmark_multi_node.sbatch
${
dim
}
${
nodes
}
${
gpus
}
${
batch_size
}
${
iteration
}
sleep
1
# pause to be kind to the scheduler
done
done
done
done
done
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment