Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
orangefs
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
GitLab upgrade completed. Current version is 17.11.3.
Show more breadcrumbs
nixos-compose
HPC IO
orangefs
Commits
3a64eb35
Commit
3a64eb35
authored
2 years ago
by
GUILLOTEAU Quentin
Browse files
Options
Downloads
Patches
Plain Diff
add snakefile
parent
b3526f37
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
Snakefile
+90
-0
90 additions, 0 deletions
Snakefile
flake.lock
+27
-0
27 additions, 0 deletions
flake.lock
flake.nix
+60
-0
60 additions, 0 deletions
flake.nix
with
177 additions
and
0 deletions
Snakefile
0 → 100644
+
90
−
0
View file @
3a64eb35
PATH_HERE="/home/quentin/ghq/gitlab.inria.fr/nixos-compose/hpc-io/orangefs"
RESULT_FOLDER=f"{PATH_HERE}/data"
FLAVOURS = [
"g5k-image"
]
NB_CPU_NODES = [
8, 16, 24, 32
]
NB_IO_NODES = [
1, 2, 4
]
BLOCK_SIZES = [
"1M",
"10M",
"100M"
# "1G",
]
FIGS = [
"ratio_folding.pdf"
]
EXPES_RESULTS = expand(["{path_here}/data/json_zip/results_ior_{nb_cpu_nodes}_cpu_nodes_{nb_io_nodes}_io_nodes_{block_size}_block_size_{flavour}.zip"], path_here=PATH_HERE,
flavour=FLAVOURS,
nb_cpu_nodes=NB_CPU_NODES,
nb_io_nodes=NB_IO_NODES,
block_size=BLOCK_SIZES)
rule all:
input:
EXPES_RESULTS,
expand(["figs/{name}"], name=FIGS)
rule build_nxc_image:
input:
"nxc/flake.nix",
"nxc/flake.lock",
"nxc/composition.nix",
"nxc/my_scripts.nix",
"nxc/script_ior.nix"
output:
"nxc/build/composition::{flavour}"
shell:
"cd nxc; nix develop --command nxc build -f {wildcards.flavour}"
rule run_ior:
input:
"nxc/build/composition::{flavour}"
output:
"{PATH_HERE}/data/json_zip/results_ior_{nb_cpu_nodes}_cpu_nodes_{nb_io_nodes}_io_nodes_{block_size}_block_size_{flavour}.zip"
shell:
"cd nxc; nix develop --command python3 script.py --nxc_build_file {PATH_HERE}/{input} --nb_cpu_nodes {wildcards.nb_cpu_nodes} --nb_io_nodes {wildcards.nb_io_nodes} --block_size {wildcards.block_size} --result_dir {RESULT_FOLDER} --flavour {wildcards.flavour} --outfile {output} --walltime 5"
rule json_to_csv:
input:
"analysis/ior_json_to_csv.py",
"{PATH_HERE}/data/json_zip/results_ior_{nb_cpu_nodes}_cpu_nodes_{nb_io_nodes}_io_nodes_{block_size}_block_size_{flavour}.zip"
output:
"{PATH_HERE}/data/csv_zip/results_csv_ior_{nb_cpu_nodes}_cpu_nodes_{nb_io_nodes}_io_nodes_{block_size}_block_size_{flavour}.zip"
shell:
"nix develop .#python --command python3 {input} {output}"
rule generate_csv:
input:
"{PATH_HERE}/analysis/zip_to_csv.R",
"{PATH_HERE}/data/csv_zip/results_csv_ior_{nb_cpu_nodes}_cpu_nodes_{nb_io_nodes}_io_nodes_{block_size}_block_size_{flavour}.zip"
output:
"{PATH_HERE}/data/csv/{nb_cpu_nodes}_{nb_io_nodes}_{block_size}_{flavour}.csv"
shell:
"nix develop .#rshell --command Rscript {input} {output} {wildcards.nb_cpu_nodes} {wildcards.nb_io_nodes} {wildcards.block_size}"
rule generate_plots:
input:
"analysis/plot_{plot_name}.R",
expand(["{path_here}/data/csv/{nb_cpu_nodes}_{nb_io_nodes}_{block_size}_{flavour}.csv"], path_here=PATH_HERE, flavour=FLAVOURS, nb_cpu_nodes=NB_CPU_NODES, nb_io_nodes=NB_IO_NODES, block_size=BLOCK_SIZES),
output:
"figs/{plot_name}.pdf"
shell:
"nix develop .#rshell --command Rscript {input} {output}"
This diff is collapsed.
Click to expand it.
flake.lock
0 → 100644
+
27
−
0
View file @
3a64eb35
{
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1659446231,
"narHash": "sha256-hekabNdTdgR/iLsgce5TGWmfIDZ86qjPhxDg/8TlzhE=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "eabc38219184cc3e04a974fe31857d8e0eac098d",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-21.11",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}
This diff is collapsed.
Click to expand it.
flake.nix
0 → 100644
+
60
−
0
View file @
3a64eb35
{
description
=
"A very basic flake"
;
inputs
=
{
nixpkgs
.
url
=
"github:NixOS/nixpkgs/nixos-21.11"
;
};
outputs
=
{
self
,
nixpkgs
}:
let
system
=
"x86_64-linux"
;
pkgs
=
import
nixpkgs
{
inherit
system
;
};
rPkgs
=
with
pkgs
.
rPackages
;
[
tidyverse
modelr
ggh4x
];
myR
=
pkgs
.
rWrapper
.
override
{
packages
=
rPkgs
;
};
rmdPkgs
=
with
pkgs
.
rPackages
;
[
rmarkdown
markdown
knitr
tinytex
magick
codetools
];
myRmd
=
pkgs
.
rWrapper
.
override
{
packages
=
rPkgs
++
rmdPkgs
;
};
myRstudio
=
pkgs
.
rstudioWrapper
.
override
{
packages
=
rPkgs
++
rmdPkgs
;
};
in
{
devShells
.
${
system
}
=
{
default
=
pkgs
.
mkShell
{
buildInputs
=
[
pkgs
.
graphviz
pkgs
.
snakemake
];
};
python
=
pkgs
.
mkShell
{
buildInputs
=
[
pkgs
.
python3
];
};
rshell
=
pkgs
.
mkShell
{
buildInputs
=
[
myR
];
};
rmdshell
=
pkgs
.
mkShell
{
buildInputs
=
with
pkgs
;
[
myRmd
pandoc
texlive
.
combined
.
scheme-full
];
};
rmddev
=
pkgs
.
mkShell
{
buildInputs
=
with
pkgs
;
[
myRstudio
pandoc
texlive
.
combined
.
scheme-full
];
};
};
};
}
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