zoukankan      html  css  js  c++  java
  • Jupyter安装第三方库和切换pip镜像源

    # JJU_干干

    1. 在Jupyter中安装第三方库和在本地安装类似,区别在于,Jupyter要在开头加一个感叹号。

      

    !pip install 某包

    2. 但这样往往下载较慢或者出现错误(以 lightgbm 为例):

      

      因此我们需要切换国内的镜像源更快速方便的下载,类似于本地切换镜像源类似,也是开头多加一个感叹号。

      以安装 lightgbm,切换清华源为例:

      

     

    代码例子:

    ! pip install lightgbm -i https://pypi.tuna.tsinghua.edu.cn/simple

    代码形式:

    ! pip install 某包 -i 某镜像源

    国内常用的镜像源:

    清华大学: https://pypi.tuna.tsinghua.edu.cn/simple/
    阿里云: https://mirrors.aliyun.com/pypi/simple/
    中国科技大学: https://pypi.mirrors.ustc.edu.cn/simple/
    豆瓣: http://pypi.douban.com/simple/
    中国科学技术大学: http://pypi.mirrors.ustc.edu.cn/simple/
    华中理工大学:http://pypi.hustunique.com/simple/
    山东理工大学:http://pypi.sdutlinux.org/simple/
  • 相关阅读:
    B树
    23查找树和红黑树
    红黑树---满足红黑性质的二叉查找树
    AVL树---平衡的二叉查找树
    二叉查找树
    Ping程序
    ICMP:Internet控制报文协议
    Unix&Linux大学教程目录
    Linux文件系统
    git简介
  • 原文地址:https://www.cnblogs.com/ZZG-GANGAN/p/13052581.html
Copyright © 2011-2022 走看看