Last active
September 23, 2018 17:33
-
-
Save reubenjohn/b714de7b47202a379642e30fd97e5853 to your computer and use it in GitHub Desktop.
Convenience shell script to launch 2 riders and 2 horses of the tensorflow distributed example: "distributed_horse_rider"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Note this script is part of the distributed_horse_rider example over hosted at: | |
# https://github.com/Project-MANAS/distributed_horse_rider | |
touch "/tmp/dhr.sh"; chmod +x "/tmp/dhr.sh" | |
launch(){ | |
for ((i=0;i<$1;i++)) | |
do | |
echo "python3.5 -m distributed_horse_rider.${2} ${i}" > "/tmp/dhr.sh" && gnome-terminal -x "/tmp/dhr.sh" | |
done | |
} | |
launch 2 horse | |
launch 2 rider |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Feel free to tweak it as per your needs and system :)