set server to be not trainable too; refactor visualization script

This commit is contained in:
René Knaebel 2017-09-07 15:31:04 +02:00
parent 5bd8e41711
commit 71f218888d
2 changed files with 24 additions and 0 deletions

23
fancy.sh Normal file
View File

@ -0,0 +1,23 @@
#!/usr/bin/env bash
RESDIR=$1
DATADIR=$2
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/both_small_final --test ${DATADIR}/futureData.csv --model_output both
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/both_small_inter --test ${DATADIR}/futureData.csv --model_output both
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/client_small_final --test ${DATADIR}/futureData.csv --model_output client
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/client_small_inter --test ${DATADIR}/futureData.csv --model_output client
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/both_medium_final --test ${DATADIR}/futureData.csv --model_output both
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/both_medium_inter --test ${DATADIR}/futureData.csv --model_output both
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/client_medium_final --test ${DATADIR}/futureData.csv --model_output client
python3 main.py --mode fancy --batch 1024 --model ${RESDIR}/client_medium_inter --test ${DATADIR}/futureData.csv --model_output client
python3 main.py --mode all_fancy --batch 256 --test ${DATADIR}/futureData.csv \
--models ${RESDIR}/*_small_*/ --out-prefix ${RESDIR}/small
python3 main.py --mode all_fancy --batch 256 --test ${DATADIR}/futureData.csv \
--models ${RESDIR}/*_medium_*/ --out-prefix ${RESDIR}/medium
python3 main.py --mode all_fancy --batch 256 --test ${DATADIR}/futureData.csv \
--models ${RESDIR}/*/ --out-prefix ${RESDIR}/all

View File

@ -180,6 +180,7 @@ def main_train(param=None):
class_weight=custom_class_weights)
model.get_layer("dense_server").trainable = False
model.get_layer("server").trainable = False
model.compile(optimizer='adam',
loss='binary_crossentropy',
loss_weights={"client": 1.0, "server": 0.0},