Commit 73dc38ef authored by Peter Parente's avatar Peter Parente Committed by GitHub

Merge pull request #595 from whosford/docker-stacks-update-tensorflow-readme

Update tensorflow-notebook readme with distributed mode instructions
parents a995da5c f9c74a16
......@@ -17,9 +17,11 @@ docker run -it --rm -p 8888:8888 jupyter/tensorflow-notebook
Take note of the authentication token included in the notebook startup log messages. Include it in the URL you visit to access the Notebook server or enter it in the Notebook login form.
## Tensorflow Single Machine Mode
## Tensorflow Machine Mode
As distributed tensorflow is still immature, we currently only provide the single machine mode.
Tensorflow can use single machine, or distributed mode.
Single machine mode:
```
import tensorflow as tf
......@@ -33,6 +35,21 @@ sess.run(init)
sess.run(hello)
```
Distributed mode:
```
import tensorflow as tf
hello = tf.Variable('Hello Distributed World!')
server = tf.train.Server.create_local_server()
sess = tf.Session(server.target)
init = tf.global_variables_initializer()
sess.run(init)
sess.run(hello)
```
## Notebook Options
The Docker container executes a [`start-notebook.sh` script](../base-notebook/start-notebook.sh) script by default. The `start-notebook.sh` script handles the `NB_UID`, `NB_GID` and `GRANT_SUDO` features documented in the next section, and then executes the `jupyter notebook`.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment