ML学习笔记(2)给萌新的自己科普一下

2.pip install和conda install区别何在?

什么是 pip ?pipPython 中的标准库管理器。它允许你安装和管理不属于 Python标准库 的其它软件包。

我找到了一下说明:

Having been involved in the python world for so long, we are all aware of pip, easy_install, and virtualenv, but these tools did not meet all of our specific requirements. The main problem is that they are focused around Python, neglecting non-Python library dependencies, such as HDF5, MKL, LLVM, etc., which do not have a setup.py in their source code and also do not install files into Python’s site-packages directory. So Conda is a packaging tool and installer that aims to do more than what pip does; handle library dependencies outside of the Python packages as well as the Python packages themselves. Conda also creates a virtual environment, like virtualenv does. As such, Conda should be compared to Buildout perhaps, another tool that lets you handle both Python and non-Python installation tasks. Because Conda introduces a new packaging format, you cannot use pip and Conda interchangeably; pip cannot install the Conda package format. You can use the two tools side by side but they do not interoperate either.

看完我恍然大悟,怪不得我用pip安装pytorch它一直提示我没有setup.py,原来出自这里!

Conda和pip不是竞争对手,而是侧重于不同用户组和使用模式的工具。Conda是一个通用的包管理器,当初设计来管理任何语言的包。所以用来管理python包当然也是绰绰有余,Conda 和 pip 目标并不相同, 只有小部分子集有交集有竞争关系:比如python包的安装和环境隔离。pip可以允许你在任何环境中安装python包,而conda允许你在conda环境中安装任何语言包(包括c语言或者python)

3.Tensorflow和Pytorch

tensorflow是谷歌开源的深度学习框架,pytorch是facebook开源的深度学习框架。

深度学习框架也就像Caffe、tensorflow这些是深度学习的工具,简单来说就是库,编程时需要import caffe、import tensorflow。作一个简单的比喻,一套深度学习框架就是这个品牌的一套积木,各个组件就是某个模型或算法的一部分,你可以自己设计如何使用积木去堆砌符合你数据集的积木。好处是你不必重复造轮子,模型也就是积木,是给你的,你可以直接组装,但不同的组装方式,也就是不同的数据集则取决于你。

总结下来就是减少工作量的工具,以后要常常与之为伴了!

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值