mathine learning,开始kaggle

来源:互联网 发布:知乎 驱动 微软认证 编辑:程序博客网 时间:2024/05/18 16:15

期末作业,要在kaggle上完成Digit Recognizer

https://www.kaggle.com/c/digit-recognizer

毫无思路,但是这东西比较有意思。我想:

1.想做一个程序把所有坐标对应打印出来,MFC,JAVA哪个比较好?

2.查看了下解决手写数字识别的几个思路, SVM,random forest algorithm(随机森林)

用python做练习(0基础python LOL),遇到好多问题。 安装python3.3后问题真TM多,看了篇文章说3.3是垃圾,忘记链接了,果断换2.7.

Python 3.3easy_install 有问题换成2.7 可以

需要安装python-numpy python-scipypython-matplotlib 库

虽然ML很难懂,kaggle也很牛,但是他给了入门代码很给力。

https://www.kaggle.com/wiki/GettingStartedWithPythonForDataScience

练习需要用到许多库(如下),所以就试着安装。

  • numpy - (pronouncednum-pie) Powerful numerical arrays. A foundational package for the two packages below.
  • scipy - (sigh-pie) Scientific, mathematical, and engineering package
  • scikit-learn - Easy to use machine learning library

第一安装NUMPY

下载numpy-1.8.0-win32-superpack-python2.7后无法找到pthyon路径

解决:

http://hi.baidu.com/lszmker/item/893ebee08355dae3fa42ba8f

注册完发现安装32位的了。。。

简单跑

import numpy as np

a = np.arange(10)

print(a)

出错:ImportError: DLL load failed: %1 isnot a valid Win32 application.

找到64位安装后解决。

在这里:http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy  numpy-MKL-1.7.2rc1.win-amd64-py2.7.exe

 

第二安装matplotlib  用easy_install有的时候不一定安装正确,所以就手工一步一步装包吧。

http://matplotlib.org/downloads.html

 

安装运行程序出错 :

ImportError:matplotlib requires dateutil  发现还要安装dateutil、pyparsing、six包。安装后

Importpylab as pl 终于不报错。

 

第三部 安装sklearn

还需安装SciPy 都在uci这下面找:

http://www.lfd.uci.edu/~gohlke/pythonlibs/

终于可以跑sklearn!了


0 0
原创粉丝点击