如何使用TensorFlow(Windows)为Udacity Deep Learning课程设置学习环境 [英] How to setup learning environment for Udacity Deep Learning class with TensorFlow (Windows)

查看:769
本文介绍了如何使用TensorFlow(Windows)为Udacity Deep Learning课程设置学习环境的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我相信很多有兴趣学习DL的学生听说过这个课程:






  • 转到 vdocker 机器的设置...






  • 添加端口转发(将虚拟环境中的8888端口转发到本地机器上的8810端口):





PS 使用:8810端口,以防您已经有IPython笔记本安装在本地机器上。


  1. 在设置...菜单(从上一步)允许虚拟机更多的内存:




NB必须关闭VirtualBox才能对系统设置进行任何更改。



使用以下命令停止VM:



docker-machine stop vdocker




(可选)您还可以允许它使用更多的内核以便运行速度更快:




  1. 利润!


I believe many of those interested in studying DL heard of this course:

https://www.udacity.com/course/deep-learning--ud730

I am taking the course now and would like to share step-by-step instruction on how to setup learning environment on Windows from scratch.

  • The first answer named SETTING UP THE ENVIRONMENT is about setting up the learning environment. You run it only once.

  • The second answer named AFTER LOCAL MACHINE REBOOT is about how to start the environment over after you reboot your computer.

  • See the third answer named HOW IT ALL WORKS to learn how all that stuff works (or you can follow the first answer blindly and check it out later).

解决方案

SETTING UP THE ENVIRONMENT (run it only once!)

N.B. To start ready environment after computer reboot, use AFTER LOCAL MACHINE REBOOT instruction in the second answer.


Steps:

  1. Download and setup Docker Toolbox:

https://www.docker.com/products/docker-toolbox

Docker is a tool to deploy preconfigured virtual learning environment on your machine. It will be running inside a virtual machine and will not mess with your computer anyhow.

  1. (optional step) Docker will put it's files on system disk (C:) and you might want to change that if using SSD. You can do it that way:

mklink /J "C:\Users\USER\.docker" "D:\Docker"

  • substitute USER with your username
  • substitute "D:\Docker" with a path on other drive where you would like to store Docker files

More at: Change .docker directory on Windows

  1. Open Windows CMD. Go to folder where Docker is installed. Create a new docker machine:

docker-machine create vdocker -d virtualbox

  1. (magic step) Just run it!

FOR /f "tokens=*" %i IN ('docker-machine env --shell cmd vdocker') DO %i

More at: How do I start tensorflow docker jupyter notebook

  1. Download and install preconfigured assignment docker image:

docker run -it -p 8888:8888 -p 6006:6006 --name tensorflow-udacity -it b.gcr.io/tensorflow-udacity/assignments:0.5.0

  1. (important step!) Configure port forwarding:
    • Run Oracle VM VirtualBox link (should be created when installing Docker):

  • Go to Settings... of vdocker machine:

  • Add port forwarding (it will forward 8888 port in virtual environment to 8810 port on your local machine):

P.S. Using :8810 port in case you already have IPython notebook installed on your local machine.

  1. In the Settings... menu (from the previous step) allow virtual machine more memory:

N.B. The VirtualBox has to be shut down before you can make any changes to system settings. (by jlarsch)

Use the following command to stop the VM:

docker-machine stop vdocker

(optional) You can also allow it to use more cores in order to run faster:

  1. Profit!

这篇关于如何使用TensorFlow(Windows)为Udacity Deep Learning课程设置学习环境的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆