According to Algorithm 2, there is a parameter gamma in the input which measures how much local
computation is performed to solve the local subproblem on device k at the t-th round.
But I can't find gamma in the code implemention.
In (https://github.com/litian96/FedProx/blob/master/flearn/models/mnist/mclr.py) there is only a variable num_epochs.
def solve_inner(self, data, num_epochs=1, batchsize=32):
'''Solves local optimization problem'''
for in trange(num_epochs, desc='Epoch: ', leave=False, ncols=120):
for X, y in batch_data(data, batch_size):
with self.graph.as_default():
self.sess.run(self.train_op,
feed_dict={self.features: X, self.labels: y})
soln = self.get_params()
comp = num_epochs (len(data['y'])//batch_size) batch_size * self.flops
return soln, comp
So could please help me find gamma?
According to Algorithm 2, there is a parameter gamma in the input which measures how much local computation is performed to solve the local subproblem on device k at the t-th round. But I can't find gamma in the code implemention. In (https://github.com/litian96/FedProx/blob/master/flearn/models/mnist/mclr.py) there is only a variable num_epochs. def solve_inner(self, data, num_epochs=1, batchsize=32): '''Solves local optimization problem''' for in trange(num_epochs, desc='Epoch: ', leave=False, ncols=120): for X, y in batch_data(data, batch_size): with self.graph.as_default(): self.sess.run(self.train_op, feed_dict={self.features: X, self.labels: y}) soln = self.get_params() comp = num_epochs (len(data['y'])//batch_size) batch_size * self.flops return soln, comp So could please help me find gamma?