You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@systemds.apache.org by se...@apache.org on 2021/10/19 14:12:22 UTC

[systemds] branch master updated: [SYSTEMDS-3148] Federated ALS Performance Tests

This is an automated email from the ASF dual-hosted git repository.

sebwrede pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/systemds.git


The following commit(s) were added to refs/heads/master by this push:
     new 9d1053c  [SYSTEMDS-3148] Federated ALS Performance Tests
9d1053c is described below

commit 9d1053c0af7f2f041a27e5231037ce1153961998
Author: ywcb00 <yw...@ywcb.org>
AuthorDate: Fri Oct 1 12:27:27 2021 +0200

    [SYSTEMDS-3148] Federated ALS Performance Tests
    
    This commit adds the first federated performance test, ALS-CG.
    The script generates the data, creates a specific amount (in our case 5) of federated worker processes on localhost, splits the data into partitions, creates a federated object from the different partitions and workers, runs the ALS-CG algorithm with the federated object as data input, and kills the worker processes again.
    The shell scripts for starting and killing the federated workers and the scripts for splitting the data and creating a federated object can be used to create other federated performance tests.
    Closes #1409.
---
 .gitignore                                         |  5 +-
 scripts/datagen/genRandData4ALS.dml                |  4 +-
 scripts/perftest/conf/log4j-off.properties         |  1 +
 .../perftest/fed/data/splitAndMakeFederated.dml    | 65 ++++++++++++++++++++
 scripts/perftest/fed/runALSFed.sh                  | 58 ++++++++++++++++++
 .../log4j-off.properties => fed/runAllFed.sh}      | 36 ++++++++---
 .../utils/killFedWorkers.sh}                       | 28 ++++++---
 scripts/perftest/fed/utils/startFedWorkers.sh      | 71 ++++++++++++++++++++++
 scripts/perftest/genALSData.sh                     | 50 +++++++++++++++
 .../{conf/log4j-off.properties => runALS.sh}       | 37 ++++++++---
 scripts/perftest/runAll.sh                         |  1 +
 .../log4j-off.properties => scripts/alsCG.dml}     | 23 ++++---
 12 files changed, 338 insertions(+), 41 deletions(-)

diff --git a/.gitignore b/.gitignore
index f464c15..30741f0 100644
--- a/.gitignore
+++ b/.gitignore
@@ -116,4 +116,7 @@ scripts/perftest/results
 scripts/perftest/logs
 scripts/perftest/in
 scripts/perftest/scratch_space
-scripts/perftest/temp
\ No newline at end of file
+scripts/perftest/temp
+scripts/perftest/fed/results
+scripts/perftest/fed/scratch_space
+scripts/perftest/fed/temp
diff --git a/scripts/datagen/genRandData4ALS.dml b/scripts/datagen/genRandData4ALS.dml
index eb9a4a9..f6c3562 100644
--- a/scripts/datagen/genRandData4ALS.dml
+++ b/scripts/datagen/genRandData4ALS.dml
@@ -20,8 +20,8 @@
 #-------------------------------------------------------------
 
 Xfile = $X; # input matrix X of size m x n
-Ufile = $U; # original row factor of size m x r
-Vfile = $V; # original col factor of size r x n
+Ufile = ifdef($U, " "); # original row factor of size m x r
+Vfile = ifdef($V, " "); # original col factor of size r x n
 m = $rows; # no. of rows of X
 n = $cols; # no. of cols of X
 r = $rank; # rank of factorization
diff --git a/scripts/perftest/conf/log4j-off.properties b/scripts/perftest/conf/log4j-off.properties
index a98837d..bbbee4d 100755
--- a/scripts/perftest/conf/log4j-off.properties
+++ b/scripts/perftest/conf/log4j-off.properties
@@ -24,6 +24,7 @@ log4j.rootLogger=ALL, console
 log4j.logger.org.apache.sysds=INFO
 log4j.logger.org.apache.spark=ERROR
 log4j.logger.org.apache.hadoop=ERROR
+log4j.logger.io.netty=INFO
 
 log4j.appender.console=org.apache.log4j.ConsoleAppender
 log4j.appender.console.target=System.err
diff --git a/scripts/perftest/fed/data/splitAndMakeFederated.dml b/scripts/perftest/fed/data/splitAndMakeFederated.dml
new file mode 100644
index 0000000..c301bd0
--- /dev/null
+++ b/scripts/perftest/fed/data/splitAndMakeFederated.dml
@@ -0,0 +1,65 @@
+#-------------------------------------------------------------
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#-------------------------------------------------------------
+
+# This script splits the specified data into $nSplit equal parts, creates the
+# federated object with respect to the hosts, and writes the federated object
+# to the location specified by $target.
+
+data = $data;
+# Read in the dataset
+X = read(data);
+hosts = read($hosts);
+nSplit = $nSplit;
+transposed = ifdef($transposed, FALSE);
+target = ifdef($target, data + "_fed.json");
+fmt = ifdef($fmt, "text");
+
+if(transposed) # for column partitions we simply transpose the data before splitting
+  X = t(X);
+
+N = nrow(X);
+M = ncol(X);
+
+factor = as.integer(floor(N / nSplit)); # number of rows per partition
+
+addresses = list();
+ranges = list();
+
+# Split the dataset into $nSplit parts
+for (counter in 1:nSplit) {
+  beginDim = (counter - 1) * factor + 1; # begin dimension of the partition
+  endDim = counter * factor; # end dimension of the partition
+  X_part = X[beginDim:endDim, ]; # select the partition from the dataset
+  write(X_part, data + counter, format=fmt); # write the partition to disk
+  # collect the addresses and ranges for creating a federated object
+  addresses = append(addresses, as.scalar(hosts[counter]) + "/" + data + counter);
+  if(transposed) {
+    ranges = append(ranges, list(0, beginDim - 1));
+    ranges = append(ranges, list(M, endDim));
+  }
+  else {
+    ranges = append(ranges, list(beginDim - 1, 0));
+    ranges = append(ranges, list(endDim, M));
+  }
+}
+
+X_fed = federated(addresses=addresses, ranges=ranges);
+write(X_fed, target, format="federated"); # write the federated object to disk
diff --git a/scripts/perftest/fed/runALSFed.sh b/scripts/perftest/fed/runALSFed.sh
new file mode 100755
index 0000000..9204d50
--- /dev/null
+++ b/scripts/perftest/fed/runALSFed.sh
@@ -0,0 +1,58 @@
+#!/bin/bash
+#-------------------------------------------------------------
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#-------------------------------------------------------------
+
+CMD=${1:-"systemds"}
+DATADIR=${2:-"temp"}/als
+NUMFED=${3:-4}
+MAXITR=${4:-100}
+
+FILENAME=$0
+err_report() {
+  echo "Error in $FILENAME on line $1"
+}
+trap 'err_report $LINENO' ERR
+
+# Set properties
+export SYSDS_QUIET=1
+
+BASEPATH=$(dirname "$0")
+
+${BASEPATH}/../genALSData.sh systemds $DATADIR; # generate the data
+
+# start the federated workers on localhost
+${BASEPATH}/utils/startFedWorkers.sh systemds $DATADIR $NUMFED "localhost";
+
+for d in "10k_1k_dense" "10k_1k_sparse" # "100k_1k_dense" "100k_1k_sparse" "1M_1k_dense" "1M_1k_sparse" "10M_1k_dense" "10M_1k_sparse" "100M_1k_dense" "100M_1k_sparse"
+do
+  # split the generated data into paritions and create a federated object
+  ${CMD} -f ${BASEPATH}/data/splitAndMakeFederated.dml \
+    --config ${BASEPATH}/../conf/SystemDS-config.xml \
+    --nvargs data=${DATADIR}/X${d} nSplit=$NUMFED transposed=FALSE \
+      target=${DATADIR}/X${d}_fed.json hosts=${DATADIR}/workers/hosts fmt="csv"
+
+  echo "-- Running ALS-CG with federated data ("$d") on "$NUMFED" federated workers" >> results/times.txt
+
+  # run the als algorithm on the federated object
+  ${BASEPATH}/../runALS.sh ${DATADIR}/X${d}_fed.json $MAXITR $DATADIR systemds 0.001 FALSE;
+done
+
+${BASEPATH}/utils/killFedWorkers.sh $DATADIR; # kill the federated workers
diff --git a/scripts/perftest/conf/log4j-off.properties b/scripts/perftest/fed/runAllFed.sh
similarity index 65%
copy from scripts/perftest/conf/log4j-off.properties
copy to scripts/perftest/fed/runAllFed.sh
index a98837d..d142af4 100755
--- a/scripts/perftest/conf/log4j-off.properties
+++ b/scripts/perftest/fed/runAllFed.sh
@@ -1,3 +1,4 @@
+#!/bin/bash
 #-------------------------------------------------------------
 #
 # Licensed to the Apache Software Foundation (ASF) under one
@@ -7,9 +8,9 @@
 # to you under the Apache License, Version 2.0 (the
 # "License"); you may not use this file except in compliance
 # with the License.  You may obtain a copy of the License at
-#
+# 
 #   http://www.apache.org/licenses/LICENSE-2.0
-#
+# 
 # Unless required by applicable law or agreed to in writing,
 # software distributed under the License is distributed on an
 # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -19,13 +20,28 @@
 #
 #-------------------------------------------------------------
 
-log4j.rootLogger=ALL, console
+COMMAND=${1:-"systemds"}
+TEMPFOLDER=${2:-"temp"}
+
+DATADIR=${TEMPFOLDER}/fed
+
+NUMFED=5
+
+FILENAME=$0
+err_report() {
+  echo "Error in $FILENAME on line $1"
+}
+trap 'err_report $LINENO' ERR
+
+BASEPATH=$(dirname "$0")
+
+# Set properties
+export LOG4JPROP=${BASEPATH}'/../conf/log4j-off.properties'
+export SYSDS_QUIET=1
+
+if [ ! -d results ]; then mkdir -p results ; fi
+
+echo "RUN FEDERATED EXPERIMENTS: "$(date) >> results/times.txt
 
-log4j.logger.org.apache.sysds=INFO
-log4j.logger.org.apache.spark=ERROR
-log4j.logger.org.apache.hadoop=ERROR
+${BASEPATH}/runALSFed.sh systemds $DATADIR $NUMFED
 
-log4j.appender.console=org.apache.log4j.ConsoleAppender
-log4j.appender.console.target=System.err
-log4j.appender.console.layout=org.apache.log4j.PatternLayout
-log4j.appender.console.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{2}: %m%n
diff --git a/scripts/perftest/conf/log4j-off.properties b/scripts/perftest/fed/utils/killFedWorkers.sh
similarity index 70%
copy from scripts/perftest/conf/log4j-off.properties
copy to scripts/perftest/fed/utils/killFedWorkers.sh
index a98837d..5c71aa8 100755
--- a/scripts/perftest/conf/log4j-off.properties
+++ b/scripts/perftest/fed/utils/killFedWorkers.sh
@@ -1,3 +1,4 @@
+#!/bin/bash
 #-------------------------------------------------------------
 #
 # Licensed to the Apache Software Foundation (ASF) under one
@@ -7,9 +8,9 @@
 # to you under the Apache License, Version 2.0 (the
 # "License"); you may not use this file except in compliance
 # with the License.  You may obtain a copy of the License at
-#
+# 
 #   http://www.apache.org/licenses/LICENSE-2.0
-#
+# 
 # Unless required by applicable law or agreed to in writing,
 # software distributed under the License is distributed on an
 # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -19,13 +20,20 @@
 #
 #-------------------------------------------------------------
 
-log4j.rootLogger=ALL, console
+# This script reads the pids of the workers from the pids-file and kills them.
+
+DATADIR=${1:-"tmp"}
+
+workerdir=${DATADIR}/workers
+
+pids=$(cat ${workerdir}/pids)
 
-log4j.logger.org.apache.sysds=INFO
-log4j.logger.org.apache.spark=ERROR
-log4j.logger.org.apache.hadoop=ERROR
+for workerpid in $pids
+do
+  echo "Killing federated worker with pid $workerpid"
+  pkill -P $workerpid
+done
 
-log4j.appender.console=org.apache.log4j.ConsoleAppender
-log4j.appender.console.target=System.err
-log4j.appender.console.layout=org.apache.log4j.PatternLayout
-log4j.appender.console.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{2}: %m%n
+rm ${workerdir}/pids
+rm -r ${workerdir}/hosts
+rm ${workerdir}/hosts.mtd
diff --git a/scripts/perftest/fed/utils/startFedWorkers.sh b/scripts/perftest/fed/utils/startFedWorkers.sh
new file mode 100755
index 0000000..691ce73
--- /dev/null
+++ b/scripts/perftest/fed/utils/startFedWorkers.sh
@@ -0,0 +1,71 @@
+#!/bin/bash
+#-------------------------------------------------------------
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#-------------------------------------------------------------
+
+# This script starts $NUMFED federated workers on free ports of localhost and
+# writes the connection info ($HOST:PORT) into a dml list.
+# The pids of the workers are collected in the pids file.
+
+CMD=${1:-"systemds"}
+DATADIR=${2:-"tmp"}
+NUMFED=${3:-4}
+HOST=${4:-"localhost"}
+
+FILENAME=$0
+err_report() {
+  echo "Error in $FILENAME on line $1"
+}
+trap 'err_report $LINENO' ERR
+
+# static json metadata for creating the list of hosts and ports of the fed workers
+hostsmtd="{\"data_type\": \"list\", \"rows\": $NUMFED, \"cols\": 1, \"format\": \"text\"}"
+singlehostmtd="{\"data_type\": \"scalar\", \"value_type\": \"string\", \"format\": \"text\"}"
+
+workerdir=${DATADIR}/workers
+hostdir=${workerdir}/hosts
+if [ ! -d $hostdir ]; then mkdir -p $hostdir ; fi
+
+echo $hostsmtd > ${hostdir}.mtd
+
+# searching for available ports in the range of 8000-65535
+startport=8000
+endport=65535
+portcounter=0
+while [ $startport -lt $endport ] && [ $portcounter -lt $NUMFED ]
+do
+  ((startport++))
+  isfree=$(ss -tulpn | grep $startport) || : # lookup if this port is free
+  if [ -z "$isfree" ]
+    then
+      echo "Starting federated worker on port "$startport" ("$((portcounter + 1))"/"$NUMFED")"
+      # start the federated worker
+      ${CMD} WORKER $startport -stats > ${workerdir}/${startport} 2>&1 &
+      workerpid=$!
+      # add the connection info to the hosts list
+      echo $HOST:$startport > ${hostdir}/${portcounter}_null
+      echo $singlehostmtd > ${hostdir}/${portcounter}_null.mtd
+      # collect the pids of the workers to kill them afterwards
+      echo $workerpid >> ${workerdir}/pids
+      ((++portcounter))
+  fi
+done
+
+echo "Successfully started "$NUMFED" federated workers"
diff --git a/scripts/perftest/genALSData.sh b/scripts/perftest/genALSData.sh
new file mode 100755
index 0000000..3c18783
--- /dev/null
+++ b/scripts/perftest/genALSData.sh
@@ -0,0 +1,50 @@
+#!/bin/bash
+#-------------------------------------------------------------
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#-------------------------------------------------------------
+
+CMD=$1
+DATADIR=$2
+
+FORMAT="binary" # can be csv, mm, text, binary
+DENSE_SP=0.9
+SPARSE_SP=0.01
+
+BASEPATH=$(dirname $0)
+
+#generate XS scenarios (80MB)
+${CMD} -f ${BASEPATH}/../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X10k_1k_dense rows=10000 cols=1000 rank=10 nnz=`echo "scale=0; 10000 * 1000 * $DENSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+${CMD} -f ${BASEPATH}/../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X10k_1k_sparse rows=10000 cols=1000 rank=10 nnz=`echo "scale=0; 10000 * 1000 * $SPARSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+
+# #generate S scenarios (800MB)
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X100k_1k_dense rows=100000 cols=1000 rank=10 nnz=`echo "scale=0; 100000 * 1000 * $DENSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X100k_1k_sparse rows=100000 cols=1000 rank=10 nnz=`echo "scale=0; 100000 * 1000 * $SPARSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+#
+# #generate M scenarios (8GB)
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X1M_1k_dense rows=1000000 cols=1000 rank=10 nnz=`echo "scale=0; 1000000 * 1000 * $DENSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X1M_1k_sparse rows=1000000 cols=1000 rank=10 nnz=`echo "scale=0; 1000000 * 1000 * $SPARSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+#
+# #generate L scenarios (80GB)
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X10M_1k_dense rows=10000000 cols=1000 rank=10 nnz=`echo "scale=0; 10000000 * 1000 * $DENSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X10M_1k_sparse rows=10000000 cols=1000 rank=10 nnz=`echo "scale=0; 10000000 * 1000 * $SPARSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+#
+# #generate XL scenarios (800GB)
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X100M_1k_dense rows=100000000 cols=1000 rank=10 nnz=`echo "scale=0; 100000000 * 1000 * $DENSE_SP" | bc` sigma=0.01 fmt=$FORMAT
+# ${CMD} -f ../datagen/genRandData4ALS.dml --nvargs X=${DATADIR}/X100M_1k_sparse rows=100000000 cols=1000 rank=10 nnz=`echo "scale=0; 100000000 * 1000 * $SPARSE_SP" | bc` sigma=0.01 fmt=$FORMAT
diff --git a/scripts/perftest/conf/log4j-off.properties b/scripts/perftest/runALS.sh
similarity index 58%
copy from scripts/perftest/conf/log4j-off.properties
copy to scripts/perftest/runALS.sh
index a98837d..0cb3524 100755
--- a/scripts/perftest/conf/log4j-off.properties
+++ b/scripts/perftest/runALS.sh
@@ -1,3 +1,4 @@
+#!/bin/bash
 #-------------------------------------------------------------
 #
 # Licensed to the Apache Software Foundation (ASF) under one
@@ -7,9 +8,9 @@
 # to you under the Apache License, Version 2.0 (the
 # "License"); you may not use this file except in compliance
 # with the License.  You may obtain a copy of the License at
-#
+# 
 #   http://www.apache.org/licenses/LICENSE-2.0
-#
+# 
 # Unless required by applicable law or agreed to in writing,
 # software distributed under the License is distributed on an
 # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -19,13 +20,29 @@
 #
 #-------------------------------------------------------------
 
-log4j.rootLogger=ALL, console
+X=$1
+MAXITER=${2:-100}
+DATADIR=${3:-"temp"}/als
+CMD=${4:-"systemds"}
+THRESHOLD=${5:-0.0001}
+VERBOSE=${6:-FALSE}
+
+FILENAME=$0
+err_report() {
+  echo "Error in $FILENAME on line $1"
+}
+trap 'err_report $LINENO' ERR
+
+tstart=$(date +%s.%N)
+
+BASEPATH=$(dirname "$0")
+
+tstart=$(date +%s.%N)
+
+${CMD} -f ${BASEPATH}/scripts/alsCG.dml \
+  --config ${BASEPATH}/conf/SystemDS-config.xml \
+  --nvargs X=$X rank=15 reg="L2" lambda=0.000001 maxiter=$MAXITER thr=$THRESHOLD verbose=$VERBOSE modelB=${DATADIR}/B modelM=${DATADIR}/M fmt="csv"
 
-log4j.logger.org.apache.sysds=INFO
-log4j.logger.org.apache.spark=ERROR
-log4j.logger.org.apache.hadoop=ERROR
+tend=$(echo "$(date +%s.%N) - $tstart - .4" | bc)
+echo "ALS-CG algorithm on "$X": "$tend >> results/times.txt
 
-log4j.appender.console=org.apache.log4j.ConsoleAppender
-log4j.appender.console.target=System.err
-log4j.appender.console.layout=org.apache.log4j.PatternLayout
-log4j.appender.console.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{2}: %m%n
diff --git a/scripts/perftest/runAll.sh b/scripts/perftest/runAll.sh
index 9886523..6b70082 100755
--- a/scripts/perftest/runAll.sh
+++ b/scripts/perftest/runAll.sh
@@ -57,6 +57,7 @@ echo "-- Generating multinomial data." >> results/times.txt;
 ./runAllBinomial.sh $CMD $TEMPFOLDER
 ./runAllMultinomial.sh $CMD $TEMPFOLDER
 ./runAllRegression.sh $CMD $TEMPFOLDER
+./fed/runAllFed.sh $CMD $TEMPFOLDER
 
 # TODO The following commented benchmarks have yet to be cleaned up and ported from perftestDeprecated to perftest
 #./runAllStats.sh $CMD $TEMPFOLDER
diff --git a/scripts/perftest/conf/log4j-off.properties b/scripts/perftest/scripts/alsCG.dml
old mode 100755
new mode 100644
similarity index 65%
copy from scripts/perftest/conf/log4j-off.properties
copy to scripts/perftest/scripts/alsCG.dml
index a98837d..f409d40
--- a/scripts/perftest/conf/log4j-off.properties
+++ b/scripts/perftest/scripts/alsCG.dml
@@ -19,13 +19,20 @@
 #
 #-------------------------------------------------------------
 
-log4j.rootLogger=ALL, console
+rank = ifdef($rank, 10);
+reg = ifdef($reg, "L2");
+lambda = ifdef($lambda, 0.000001);
+maxiter = ifdef($maxiter, 50);
+thr = ifdef($thr, 0.0001);
+verbose = ifdef($verbose, TRUE);
+modelB = ifdef($modelB, "B");
+modelM = ifdef($modelM, "M");
+fmt = ifdef($fmt, "text");
+check = ifdef($check, TRUE);
 
-log4j.logger.org.apache.sysds=INFO
-log4j.logger.org.apache.spark=ERROR
-log4j.logger.org.apache.hadoop=ERROR
+X = read($X);
 
-log4j.appender.console=org.apache.log4j.ConsoleAppender
-log4j.appender.console.target=System.err
-log4j.appender.console.layout=org.apache.log4j.PatternLayout
-log4j.appender.console.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{2}: %m%n
+[B, M] = alsCG(X=X, rank=rank, reg=reg, lambda=lambda, maxi=maxiter, check=check, thr=thr, verbose=verbose);
+
+write(B, $modelB, format=fmt);
+write(M, $modelM, format=fmt);