ds: link the resultTree in the dataset

This commit is contained in:
2021-05-03 12:48:49 +02:00
parent 760787858a
commit 6937ffcfe9
14 changed files with 53 additions and 131 deletions

View File

@@ -2,15 +2,22 @@
stdenv
}:
experiments:
datasets:
with stdenv.lib;
stdenv.mkDerivation {
name = "merge.json";
name = "merged-dataset";
preferLocalBuild = true;
phases = [ "installPhase" ];
inherit datasets;
installPhase = ''
cat ${concatStringsSep " " experiments} >> $out
mkdir -p $out
n=1
for d in $datasets; do
ln -s $d $out/$n
let n=n+1
cat $d/dataset >> $out/dataset
done
'';
}

View File

@@ -144,10 +144,10 @@ in stdenv.mkDerivation {
mkdir -p $out
cd $out
dataset="${dataset}"
dataset=$(readlink -f ${dataset}/dataset)
ln -s $dataset input
Rscript --vanilla ${script} ${dataset} "$out"
Rscript --vanilla ${script} "$dataset" "$out"
# HACK: replace the \minus for a \hyphen to keep the file paths intact, so
# they can be copied to the terminal directly. The StandardEncoding is not