Fall 2008 Lecture 4: Machine Learning - Logistic Regression & Perceptron Algorithm by S. A, Assignments of Computer Science

A part of the fall 2008 lecture notes for the machine learning (cs 567) course taught by sofus a. Macskassy at the university of southern california. The notes cover topics such as logistic regression, conditional probability distribution, and the perceptron algorithm. Students are introduced to the concept of learning conditional distributions and the use of logistic functions to estimate probabilities. The lecture also discusses the optimization of logistic regression using gradient descent and the difference between online and batch learning.

Typology: Assignments

Pre 2010

Uploaded on 02/24/2010

koofers-user-74z
koofers-user-74z šŸ‡ŗšŸ‡ø

10 documents

1 / 44

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Fall 2008 Lecture 4 - Sofus A. Macskassy1
Machine Learning (CS 567) Lecture 4
Fall 2008
Time: T-Th 5:00pm - 6:20pm
Location: GFS 118
Instructor: Sofus A. Macskassy ([email protected])
Office: SAL 216
Office hours: by appointment
Teaching assistant: Cheol Han ([email protected])
Office: SAL 229
Office hours: M 2-3, W 11-12
Class web page:
http://www-scf.usc.edu/~csci567/index.html
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c

Partial preview of the text

Download Fall 2008 Lecture 4: Machine Learning - Logistic Regression & Perceptron Algorithm by S. A and more Assignments Computer Science in PDF only on Docsity!

Fall 2008 1 Lecture 4 - Sofus A. Macskassy

Machine Learning (CS 567) Lecture 4

Fall 2008

Time: T-Th 5:00pm - 6:20pm

Location: GFS 118

Instructor : Sofus A. Macskassy ([email protected])

Office: SAL 216

Office hours: by appointment

Teaching assistant : Cheol Han ([email protected])

Office: SAL 229

Office hours: M 2-3, W 11-

Class web page:

http://www-scf.usc.edu/~csci567/index.html

Fall 2008 2 Lecture 4 - Sofus A. Macskassy

Administrative: Home work

• Due at start of class on due date.

• 25% off if after class but before 8am next morning

• 50% off if received next day after 8am

• 100% off if not received next day

• If you have a valid excuse, let me know ASAP with proper

documentation. No exceptions.

• Grading compliant policy: if students have problems at

assignment grading, feel free to talk to the instructor/TA for

it. However, even if students only request re-grading one of

the answers, all this assignment will be checked and graded

again. (take the risk of possible losing total points.)

Fall 2008 4 Lecture 4 - Sofus A. Macskassy

Project Idea: Applied Learning

Take an interesting dataset Compare several learning approaches for prediction

  • decision trees
  • ANNs
  • instance-based methods
  • SVMs
  • boosting

Fall 2008 5 Lecture 4 - Sofus A. Macskassy

Project Idea: Improvements to

Learning Methods

There are many suggestions on how to improve various learning methods, both in books and in papers. Identify some suggestions and test them empirically.

Fall 2008 7 Lecture 4 - Sofus A. Macskassy

Text Classification

Easy to get lots of text: web, TREC data,

email (e.g., enron)

Predict topic, authorship, sentiment, style,

affect, attitude.

Fall 2008 8 Lecture 4 - Sofus A. Macskassy

Reinforcement Learning

Can be challenging to do well: generate data or

direct control

• Optimize gas well production

• Object tracking

• ā€œTagā€ grid world

• Rover control

• animal behavior experiments

Compare approaches (direct policy search, value

function learning, model-based, …)

Fall 2008 10 Lecture 4 - Sofus A. Macskassy

Project Methodology

Lots of good ideas for algorithms and domains.

The hard question is: ā€œHow will you evaluate it?ā€

Ultimately, you need to present more than one

algorithm (and perhaps more than one problem)

and you’ll need some way of saying what worked

better.

What’s the gold standard?

Fall 2008 11 CS 567 Lecture 3 - Sofus A. Macskassy

Lecture 4 Outline

• Linear Threshold Units

– Perceptron

– Logistic Regression

Fall 2008 13 CS 567 Lecture 3 - Sofus A. Macskassy

Alternatively…

w

w w

w w

g g g

T
T
T T

w x

w w x

w x w x

x x x

otherwise

if 0

choose

C

C g x

Fall 2008 14 CS 567 Lecture 3 - Sofus A. Macskassy

Geometry

Fall 2008 16 CS 567 Lecture 3 - Sofus A. Macskassy

Pairwise Separation

ij
T
ij ij ij ij

g x w ,w  w x  w

don' t care otherwise

0 if

0 if

j i ij

C

C

g x

x

x

choose if

  x 

ij i

j i, g

C

Fall 2008 17 CS 567 Lecture 3 - Sofus A. Macskassy

• When learning a classifier, the natural way to

formulate the learning problem is the following:

– Given:

  • A set of N training examples {( x 1 ,y 1 ), ( x 2 ,y 2 ), …, ( x N,yN)}
  • A loss function L

– Find:

  • The weight vector w that minimizes the expected loss on the

training data

• In general, machine learning algorithms apply some

optimization algorithm to find a good hypothesis. In

this case, J is piecewise constant, which makes this

a difficult problem

J(w) =

N

X^ N i=

L(sgn(w ¢ xi); yi):

Machine Learning and Optimization

Fall 2008 19 Lecture 4 - Sofus A. Macskassy

Optimizing… what?

Hinge loss 0-1 loss

Fall 2008 20 CS 567 Lecture 3 - Sofus A. Macskassy

Optimizing… what?

w 0