added multi-node locked ip search

This commit is contained in:
William Falcon
2019-07-08 12:32:48 -04:00
parent 212eabf626
commit 6a1199b797
+1 -1
View File
@@ -365,7 +365,7 @@ class Trainer(TrainerIO):
# every process writes their process id + ip to a shared file
my_ip = subprocess.run(['hostname', '-I'], stdout=subprocess.PIPE).stdout.decode('utf-8')
my_ip = my_ip.split(' ')[0]
to_write = f'{my_ip}'
to_write = f'{my_ip}\n'
# save the ip to the file
# block file so only one process can access at a time