7
Pattern Recognition Software CS855 Week 1

Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Embed Size (px)

Citation preview

Page 1: Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Pattern Recognition Software

CS855 Week 1

Page 2: Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Matlab

• Commercial• Very fast matrix

operations• Many open source

functions• Portability limited

• Free• Interpreted language,

can be slow. C function calls are fast

• Many 3rd party libs• Portable

Python

Page 3: Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Matlab setup

• On the Pace network (on campus or VPN)– smb://vsapps.seidenberg.csis/MATLAB– Follow either the 32bit or 64bit link

Page 4: Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Python setup

• Download and install Anaconda– http://continuum.io/downloads– Includes all the major Python scientific libraries

• Pick an editor/IDE– Emacs, Aptana Studio (Eclipse + PyDev), PyCharm

• Start an Ipython Notebook$ ipython notebook

Page 5: Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Workflow

Matlab• Interactive command

prompt

Python• Editor + REPL• IPython notebook

Page 6: Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Matrix operations

Matlaba = [[1,2]]b = [[1];[2]]a.*b % element-wisea*b % matrix

Pythona = np.array([[1, 2]])b = np.array([[3],[4]])a * b # element-wisea.dot(a) # matrix

Page 7: Pattern Recognition Software CS855 Week 1. Matlab Commercial Very fast matrix operations Many open source functions Portability limited Free Interpreted

Binomial distribution

Matlabprob.BinomialDistribution

Pythonnp.random.binomial