(self, clients)
Copies server model variables to each of the given clients

        Args:
            clients: list of Client objects
Copies server model variables to each of the given clients
Copies server model variables to each of the given clients
def send_to(self, clients):
        """Copies server model variables to each of the given clients

        Args:
            clients: list of Client objects
        """
        var_vals = {}
        with self.model.graph.as_default():
            all_vars = tf.trainable_variables()
            for v in all_vars:
                val = self.model.sess.run(v)
                var_vals[v.name] = val
        for c in clients:
            with c.model.graph.as_default():
                all_vars = tf.trainable_variables()
                for v in all_vars:
                    v.load(var_vals[v.name], c.model.sess)
def send_to ( self , clients ) : var_vals = { } with self . model . graph . as_default ( ) : all_vars = tf . trainable_variables ( ) for v in all_vars : val = self . model . sess . run ( v ) var_vals [ v . name ] = val for c in clients : with c . model . graph . as_default ( ) : all_vars = tf . trainable_variables ( ) for v in all_vars : v . load ( var_vals [ v . name ] , c . model . sess )