不多说,直接上干货!

前期博客

Windows下的Python 3.6.1的下载与安装(适合32bits和64bits)(图文详解)

  这是我自定义的Python 的安装目录 (D:\SoftWare\Python\Python36\Scripts)

1、Jupyter Notebook pip

  为了更加方便地写 Python 代码,还需要安装 Jupyter notebook。 利用 pip 安装 Jupyter notebook。
  为什么要使用 Jupyter?参考: https://www.zhihu.com/question/37490497

  pip: Python 的包管理工具,安装 Python 的同时已经安装好了。
  Jupyter notebook: 一个交互式笔记本,支持运行 40 多种编程语言。 利用她来写 Python,代码和运行结果都可以保存下载,十分方便。

2、Jupyter notebook 安装

  命令行窗口输入: pip install jupyter
  切换到 D:\SoftWare\Python\Python36\Scripts目录下,

  当然,若大家是默认安装的话,则在C:\Users\Administrator\AppData\Local\Programs\Python\Python36\Scripts 目录下 。

   或者将该目录添加到 path,就不用切换了。

  我这里,因为考虑到机器学习深度学习那边,已经安装了Anaconda2和Anaconda3,所以这边的数据分析所用的python3.6.1就不添加到path了。每次去切换到这个目录来,也不麻烦。

 

  

Microsoft Windows [版本 6.1.]
版权所有 (c) Microsoft Corporation。保留所有权利。 C:\Users\Administrator>cd /d D:\ D:\>cd D:\SoftWare\Python\Python36\Scripts D:\SoftWare\Python\Python36\Scripts>pip install jupyter

  安装成功。

3、 jupyter notebook的启动
  命令行窗口输入: jupyter notebook

D:\SoftWare\Python\Python36\Scripts>jupyter notebook
[I ::02.828 NotebookApp] Serving notebooks from local directory: D:\SoftWare
\Python\Python36\Scripts
[I ::02.828 NotebookApp] active kernels
[I ::02.828 NotebookApp] The Jupyter Notebook is running at: http://localhos
t:/?token=8f82159edecad826ce9769f126402fc58f5b87b8d1050b0d
[I ::02.829 NotebookApp] Use Control-C to stop this server and shut down all
kernels (twice to skip confirmation).
[C ::02.833 NotebookApp] Copy/paste this URL into your browser when you connect for the first time,
to login with a token:
http://localhost:8888/?token=8f82159edecad826ce9769f126402fc58f5b87b8d10
50b0d
[I ::03.628 NotebookApp] GET / (::) .00ms
[I ::03.647 NotebookApp] GET /tree? (::) .00ms
[I ::05.535 NotebookApp] Accepting one-time-token-authenticated connection f
rom ::

  同时,默认浏览器会打开 Jupyter notebook 窗口。 说明 Jupyter notebook 安装成功了。

4、配置 Jupyter notebook 

jupyter notebook --generate-config

运行之前

  打开“.jupyter”文件夹,可以看到里面有个配置文件。

Microsoft Windows [版本 6.1.]
版权所有 (c) Microsoft Corporation。保留所有权利。 C:\Users\Administrator>cd /d D:\ D:\>cd D:\SoftWare\Python\Python36\Scripts D:\SoftWare\Python\Python36\Scripts>jupyter notebook --generate-config
Writing default config to: C:\Users\Administrator\.jupyter\jupyter_notebook_conf
ig.py D:\SoftWare\Python\Python36\Scripts>

  修改jupyter_notebook_config.py配置文件
  打开这个配置文件,找到“c.NotebookApp.notebook_dir=……”,把路径改成自己的工作目录。

 比如,这里要变更为

## The directory to use for notebooks and kernels.
c.NotebookApp.notebook_dir = 'D:\Code\jupyter-notebook'

,当然,文件夹 jupyter-notebook 需要自己创建好

  配置文件修改完成后, 以后在 jupyter notebook 中写的代码等都会保存在自己创建的目录中。

 jupyter notebook的自定义启动(变了)
  配置文件修改成后,就可以启动 jupyter notebook 了,命令行窗口中输入 jupyter notebook,
  默认浏览器就会打开一个页面

 jupyter notebook的启动
  命令行窗口输入: jupyter notebook

  以前是

D:\SoftWare\Python\Python36\Scripts>jupyter notebook
[I 10:37:02.828 NotebookApp] Serving notebooks from local directory: D:\SoftWare
\Python\Python36\Scripts
[I 10:37:02.828 NotebookApp] 0 active kernels
[I 10:37:02.828 NotebookApp] The Jupyter Notebook is running at: http://localhos
t:8888/?token=8f82159edecad826ce9769f126402fc58f5b87b8d1050b0d
[I 10:37:02.829 NotebookApp] Use Control-C to stop this server and shut down all
kernels (twice to skip confirmation).
[C 10:37:02.833 NotebookApp] Copy/paste this URL into your browser when you connect for the first time,
to login with a token:
http://localhost:8888/?token=8f82159edecad826ce9769f126402fc58f5b87b8d10
50b0d
[I 10:37:03.628 NotebookApp] 302 GET / (::1) 1.00ms
[I 10:37:03.647 NotebookApp] 302 GET /tree? (::1) 5.00ms
[I 10:37:05.535 NotebookApp] Accepting one-time-token-authenticated connection f
rom ::1

  现在是

Microsoft Windows [版本 6.1.]
版权所有 (c) Microsoft Corporation。保留所有权利。 C:\Users\Administrator>cd /d D:\ D:\>cd D:\SoftWare\Python\Python36\Scripts

D:\SoftWare\Python\Python36\Scripts>jupyter notebook
[I ::58.326 NotebookApp] Serving notebooks from local directory: D:\Code\jup
yter-notebook
[I ::58.327 NotebookApp] active kernels
[I ::58.327 NotebookApp] The Jupyter Notebook is running at: http://localhos
t:/?token=e520d165636db926b824bd77fe81559555ff679cc5fdc774
[I ::58.328 NotebookApp] Use Control-C to stop this server and shut down all
kernels (twice to skip confirmation).
[C ::58.332 NotebookApp] Copy/paste this URL into your browser when you connect for the first time,
to login with a token:
http://localhost:8888/?token=e520d165636db926b824bd77fe81559555ff679cc5f
dc774
[I ::59.532 NotebookApp] Accepting one-time-token-authenticated connection f
rom ::

  当然,其实啊,这个玩意非常的简单和方便。关于修改名字、上传等操作,后续关注的我博客。

常见问题及解决方案

如何添加 Path?
计算机-右击-单机“属性”

单机“高级系统设置”

  单机“环境变量”

  找到系统变量 path,编辑
在最后加上 2 个路径:
C:\Users\Administrator\AppData\Local\Programs\Python\Python36
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\Scripts
  说明:以上默认安装路径,每个电脑上是类似的,找到复制这个路径加到 Path 中即可

  我的路径是已经改了,在下面的这篇博客里,可以看到

Windows下的Python 3.6.1的下载与安装(适合32bits和64bits)(图文详解)

这是我自定义的Python 的安装目录 (D:\SoftWare\Python\Python36\Scripts)

jupyter notebook 闪退
  解决办法:更换默认浏览器。 ,建议用谷歌浏览器或者火狐浏览器

欢迎大家,加入我的微信公众号:大数据躺过的坑        人工智能躺过的坑
 
 
 

同时,大家可以关注我的个人博客

   http://www.cnblogs.com/zlslch/   和     http://www.cnblogs.com/lchzls/      http://www.cnblogs.com/sunnyDream/   

   详情请见:http://www.cnblogs.com/zlslch/p/7473861.html

  人生苦短,我愿分享。本公众号将秉持活到老学到老学习无休止的交流分享开源精神,汇聚于互联网和个人学习工作的精华干货知识,一切来于互联网,反馈回互联网。
  目前研究领域:大数据、机器学习、深度学习、人工智能、数据挖掘、数据分析。 语言涉及:Java、Scala、Python、Shell、Linux等 。同时还涉及平常所使用的手机、电脑和互联网上的使用技巧、问题和实用软件。 只要你一直关注和呆在群里,每天必须有收获

对应本平台的讨论和答疑QQ群:大数据和人工智能躺过的坑(总群)(161156071) 

Windows下的Jupyter Notebook 安装与自定义启动(图文详解)的更多相关文章

  1. Windows下的Jupyter Notebook 安装与自定义启动

    1.Jupyter Notebook 和 pip 为了更加方便地写 Python 代码,还需要安装 Jupyter notebook. 利用 pip 安装 Jupyter notebook. 为什么要 ...

  2. CentOS 6.3下Samba服务器的安装与配置方法(图文详解)

    这篇文章主要介绍了CentOS 6.3下Samba服务器的安装与配置方法(图文详解),需要的朋友可以参考下   一.简介  Samba是一个能让Linux系统应用Microsoft网络通讯协议的软件, ...

  3. Windows 7操作系统下PHP 7的安装与配置(图文详解)

    前提博客 Windows 7操作系统下Apache的安装与配置(图文详解) 从官网下载           PHP的官网 http://www.php.net/         特意,新建这么一个目录 ...

  4. Ubuntu14.04下Mongodb官网安装部署步骤(图文详解)(博主推荐)

    不多说,直接上干货! 在这篇博客里,我采用了非官网的安装步骤,来进行安装.走了弯路,同时,也是不建议.因为在大数据领域和实际生产里,还是要走正规的为好. Ubuntu14.04下Mongodb(离线安 ...

  5. Ubuntu16.04下Mongodb官网安装部署步骤(图文详解)(博主推荐)

    不多说,直接上干货! 在这篇博客里,我采用了非官网的安装步骤,来进行安装.走了弯路,同时,也是不建议.因为在大数据领域和实际生产里,还是要走正规的为好. Ubuntu16.04下Mongodb(离线安 ...

  6. Windows下的Jupyter Notebook 的介绍(写给新手)(图文详解)

    不多说,直接上干货! Windows下的Python 3.6.1的下载与安装(适合32bits和64bits)(图文详解) Windows下的Jupyter Notebook 安装与自定义启动(图文详 ...

  7. Ubuntu14.04下Mongodb数据库可视化工具安装部署步骤(图文详解)(博主推荐)

    不多说,直接上干货! 前期博客 Ubuntu14.04下Mongodb(离线安装方式|非apt-get)安装部署步骤(图文详解)(博主推荐) Ubuntu14.04下Mongodb官网安装部署步骤(图 ...

  8. Ubuntu14.04下Mongodb官网卸载部署步骤(图文详解)(博主推荐)

    不多说,直接上干货! 前期博客 Ubuntu14.04下Mongodb官网安装部署步骤(图文详解)(博主推荐) https://docs.mongodb.com/manual/tutorial/ins ...

  9. Ubuntu16.04下Mongodb官网卸载部署步骤(图文详解)(博主推荐)

    不多说,直接上干货! 前期博客 Ubuntu16.04下Mongodb官网安装部署步骤(图文详解)(博主推荐) https://docs.mongodb.com/manual/tutorial/ins ...

随机推荐

  1. oracle 数据库、实例、服务名、SID

    参考:http://www.zhetao.com/content240 在实际的开发应用中,关于Oracle数据库,经常听见有人说建立一个数据库,建立一个Instance,启动一个Instance之类 ...

  2. Xcode工程编译错误之iOS开发之Xcode9报错 Compiling IB documents for earlier than iOS7 is no longer supported.

    概要: 在我们升级到Xcode9时,最低的编译版本为iOS8,但是在使用一些SDK的时候就会报出Compiling IB documents for earlier than iOS7 is no l ...

  3. day4_局部变量和全局变量

    一.介绍: 定义在函数内部的变量拥有一个局部作用域,定义在函数外的拥有全局作用域. 局部变量意思就是在局部生效的,出了这个变量的作用域,这个变量就失效了 全局变量的意思就是在整个程序里面都生效的,在程 ...

  4. 扩容Linux文件系统

    扩容Linux文件系统 腾讯云 云硬盘扩容 https://cloud.tencent.com/product/cbs https://cloud.tencent.com/document/produ ...

  5. Redis入门到高可用(十五)—— HyperLogLog

    一.简介 二.API Demo 三.使用经验

  6. form提交循环

    使用ajax提交数据时,如果数据非常多,提交会比较麻烦,这时可以给form表一个id=“form”,用serializeArray()方法进行提交. erializeArray()方法通过序列化表单值 ...

  7. Echarts-图表根据值的不同展示成不同的颜色

    series : [        {            name:'直接访问',            type:'bar',            barWidth: '60%',      ...

  8. python数据结构-如何让字典有序

    如何让字典有序 问题举例: 统计学生的成绩和名次,让其在字典中按排名顺序有序显示,具体格式如下 {'tom':(1, 99), 'lily':(2, 98), 'david':(3, 95)} 说明 ...

  9. Android adt-bundle 开发环境的搭建_Linuxs

    本文完全是拷贝的: https://www.jb51.net/article/87957.htm  的文章, 有需要请看原文, 拷贝仅用于学习记录. 本文与<利用adt-bundle轻松搭建An ...

  10. JS数据类型及函数的预编译

    1.JS总体上分为:原始值和引用值 原始值分为:Number.Boolean.String.undefined.null;原始值不可改变的值,存储在栈[stack]的,先进后出! 引用值:array. ...