syft.workers.tfe

To be extended in the near future.

Module Contents

syft.workers.tfe.logger
syft.workers.tfe._TMP_DIR
class syft.workers.tfe.TFEWorker(host=None, auto_managed=True)
start(self, player_name, cluster)

Start the worker as a player in the given cluster. Depending on whether the worker was constructed with a host or not this may launch a subprocess running a TensorFlow server.

stop(self)

Stop the worker. This will shutdown any TensorFlow server launched in start().

connect_to_model(self, input_shape, output_shape, cluster, sess=None)

Connect to a TF Encrypted model being served by the given cluster.

This must be done before querying the model.

query_model(self, data)

Encrypt data and sent it as input to the model being served.

This will block until a result is ready, and requires that a connection to the model has already been established via connect_to_model().

query_model_async(self, data)

Asynchronous version of query_model that will not block until a result is ready. Call query_model_join to retrive result.

This requires that a connection to the model has already been established via connect_to_model().

query_model_join(self)

Retrives the result from calling query_model_async, blocking until ready.

class syft.workers.tfe.TFECluster(*workers)

A TFECluster represents a group of TFEWorkers that are aware about each other and collectively perform an encrypted computation.

property workers(self)
start(self)

Start all workers in the cluster.

stop(self)

Stop all workers in the cluster.

_build_cluster(self, workers)