Python Machine Learning
来源:互联网 发布:smo算法 python实现 编辑:程序博客网 时间:2024/06/06 05:17
今天可能是写笔记写上瘾了吧。
晚上闲来无事,准备把Mac上面在书上要用的环境搭一下。最近可能是用编辑器用惯了,简直不想用IDE。
书上第一章大概介绍了一些基础知识,有监督和无监督学习以及增强学习。介绍了一下聚类呀分类呀以及evaluating这些。
然后是装环境。
Installing Python packages
书上是基于Python version >=3.4.3.It is recommended to use Python3. And the book provide a link for difference between 3.4 and 2.7.
https://wiki.python.org/moin/Python2orPython3
But my Mac already has python 2.7 and I dont wanna install another version anymore. So I decide use 2.7 first. I would like install python3 if there are some problems with the version in the future.
Intall pip
sudo easy_install pip;
And here are some package we should install too.
- NumPy 1.9.1
- SciPy 0.14.0
- scikit-learn 0.15.2
- matplotlib 1.4.0
- pandas 0.15.2
Install Numpy
pip install numpy
Install SciPy
We need gfortran to compile SciPy but it is not included with the other Xcode tools. Luckily, Homebrew can help us out again:
brew install gfortran
which might updating your homebrew first.
I have an error bellow:
Error: No available formula with the name "gfortran" GNU Fortran is now provided as part of GCC, and can be installed with:brew install gcc
but i already got a gcc in my mac.
i’ll try just install scipy first.
that’s done it’s a cinch to install Scipy
pip install scipy
Install matplotlib
brew install pkg-configpip install matplotlib
Install scikit-learn
sudo pip install sklearn
Install pandas
sudo pip install pandas
when its all done, the following should work in Python with no errors:
import numpyimport scipyimport matplotlibimport sklearnimport pandas
- Machine Learning (Python)
- python for machine-learning
- Python Machine Learning
- Python Machine Learning : Chap2
- Python Machine Learning chap3
- Machine Learning in Python
- Machine Learning Library for Python
- Python Machine Learning---scikit-learn
- Python machine learning Ridge Regression
- Learning Scikit-learn Machine Learning in Python
- python机器学习(Python Machine Learning)
- scikit-learn: machine learning in Python
- 【ML】【python】Machine Learning in Action
- Machine Learning in Python part 1
- Machine Learning in Python part 2
- Machine Learning in Python (Scikit-learn)-(转)
- 【用Python玩Machine Learning】KNN * 序
- 【用Python玩Machine Learning】KNN * 测试
- 求结构体的偏移量方法
- L2-010. 排座位 (并查集简单应用)
- GCC C语言处理主要函数之c_objc_common_init
- 非极大值抑制算法
- 语言数据联盟( linguistic data consortium,LDC)
- Python Machine Learning
- 移动端的布局:flex布局
- GCC C语言处理主要函数之c_common_init
- solr6.3安装部署
- 图片压缩大小清晰度测试
- CCF201403-1-相反数
- 题目1004:Median
- hibernate 自定义sql createSQLQuery多表join查询查询自定义vo对象
- ViewPage的初使用(一)