LFD Book Forum Question 11
 User Name Remember Me? Password
 FAQ Calendar Mark Forums Read

 Thread Tools Display Modes
#1
09-16-2012, 08:10 PM
 fgpancorbo Senior Member Join Date: Jul 2012 Posts: 104
Question 11

I have used LIBSVM; the answer that I get is one of a) to d) if I scale it appropriately. However, if I scale it, the margin in the transformed domain is not any more +/-1 at the support vectors. So technically the answer proposed is right (since it separates the points with a maximum margin) but it doesn't satisfy the requirement that the margins be +/- 1 at the support vectors.
#2
09-16-2012, 09:05 PM
 yaser Caltech Join Date: Aug 2009 Location: Pasadena, California, USA Posts: 1,476
Re: Question 12

Quote:
 Originally Posted by fgpancorbo I have used LIBSVM; the answer that I get is one of a) to d) if I scale it appropriately. However, if I scale it, the margin in the transformed domain is not any more +/-1 at the support vectors. So technically the answer proposed is right (since it separates the points with a maximum margin) but it doesn't satisfy the requirement that the margins be +/- 1 at the support vectors.
Just to make sure, this is a double-check on the answer as the question asks explicitly for a geometric solution. Right?
__________________
Where everyone thinks alike, no one thinks very much
#3
09-16-2012, 09:16 PM
 fgpancorbo Senior Member Join Date: Jul 2012 Posts: 104
Re: Question 12

Quote:
 Originally Posted by yaser Just to make sure, this is a double-check on the answer as the question asks explicitly for a geometric solution. Right?
Correct. I did it with LIBSVM though . I have verified that the libsvm solution provides margins equal to 1 for the support vectors. By scaling it via a positive constant I get one of the four.

Thanks,

Fernando.
#4
09-16-2012, 09:40 PM
 yaser Caltech Join Date: Aug 2009 Location: Pasadena, California, USA Posts: 1,476
Re: Question 12

Quote:
 Originally Posted by fgpancorbo Correct. I did it with LIBSVM though .
LIBSVM is getting popular . Someone even applied it to the puzzle from Lecture 1 if you remember that.

http://book.caltech.edu/bookforum/sh...21&postcount=6
__________________
Where everyone thinks alike, no one thinks very much
#5
09-16-2012, 09:58 PM
 fgpancorbo Senior Member Join Date: Jul 2012 Posts: 104
Re: Question 12

Quote:
 Originally Posted by yaser LIBSVM is getting popular . Someone even applied it to the puzzle from Lecture 1 if you remember that. http://book.caltech.edu/bookforum/sh...21&postcount=6
I guess that given that we have libsvm, my lazy inside refused to do sit down and write the problem on paper .
#6
09-17-2012, 09:51 AM
 MLearning Senior Member Join Date: Jul 2012 Posts: 56
Re: Question 12

Quote:
 Originally Posted by yaser Just to make sure, this is a double-check on the answer as the question asks explicitly for a geometric solution. Right?
Geometrically, it is clear to see what the values of the weights and b should be. My results using a geometric approach match the results I get using Octave implemenation of SVM. Of course, libsvm also confirms my results as it always has the final say in matters related to SVM .
#7
06-10-2013, 06:30 PM
 jforbes Member Join Date: Apr 2013 Posts: 12
Re: Question 12

It seems like the original question was never answered.

Geometrically, one can find a w1, w2, and b which define the separating plane. Clearly you get the same plane if you multiply w1, w2, and b by some constant A. In the SVM formalism A was fixed so that w.z+b=1 at the nearest positive point.

Do we need to
-choose the w1, w2, and b which define the correct plane AND have the correct A, or
-is it sufficient to choose one of the infinitely many w1, w2, and b which define the correct plane without necessarily having the correct normalization A?

It's also possible that the correct answer has the correct normalization and I've made some mistake.
#8
06-10-2013, 06:50 PM
 yaser Caltech Join Date: Aug 2009 Location: Pasadena, California, USA Posts: 1,476
Re: Question 12

Quote:
 Originally Posted by jforbes Geometrically, one can find a w1, w2, and b which define the separating plane. Clearly you get the same plane if you multiply w1, w2, and b by some constant A. In the SVM formalism A was fixed so that w.z+b=1 at the nearest positive point. Do we need to -choose the w1, w2, and b which define the correct plane AND have the correct A, or -is it sufficient to choose one of the infinitely many w1, w2, and b which define the correct plane without necessarily having the correct normalization A?
It is the latter, with no normalization needed. Since the wording of the problem asks for what values specify the plane, a set of values that does specify the plane would be the correct answer and if none of them does then it's none of the above.
__________________
Where everyone thinks alike, no one thinks very much
#9
06-10-2013, 07:24 PM
 jforbes Member Join Date: Apr 2013 Posts: 12
Re: Question 12

Quote:
 Originally Posted by yaser It is the latter, with no normalization needed. Since the wording of the problem asks for what values specify the plane, a set of values that does specify the plane would be the correct answer and if none of them does then it's none of the above.
Great - looking back I agree that the question wording is unambiguous, though perhaps for this problem the graph of P(getting the right answer) vs Carefulness is non-monotonic. Thank you!
#10
06-10-2013, 07:35 PM
 yaser Caltech Join Date: Aug 2009 Location: Pasadena, California, USA Posts: 1,476
Re: Question 12

Quote:
 Originally Posted by jforbes the graph of P(getting the right answer) vs Carefulness is non-monotonic
__________________
Where everyone thinks alike, no one thinks very much

 Thread Tools Display Modes Linear Mode

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is Off Forum Rules
 Forum Jump User Control Panel Private Messages Subscriptions Who's Online Search Forums Forums Home General     General Discussion of Machine Learning     Free Additional Material         Dynamic e-Chapters         Dynamic e-Appendices Course Discussions     Online LFD course         General comments on the course         Homework 1         Homework 2         Homework 3         Homework 4         Homework 5         Homework 6         Homework 7         Homework 8         The Final         Create New Homework Problems Book Feedback - Learning From Data     General comments on the book     Chapter 1 - The Learning Problem     Chapter 2 - Training versus Testing     Chapter 3 - The Linear Model     Chapter 4 - Overfitting     Chapter 5 - Three Learning Principles     e-Chapter 6 - Similarity Based Methods     e-Chapter 7 - Neural Networks     e-Chapter 8 - Support Vector Machines     e-Chapter 9 - Learning Aides     Appendix and Notation     e-Appendices

All times are GMT -7. The time now is 12:42 AM.

 Contact Us - LFD Book - Top

Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
The contents of this forum are to be used ONLY by readers of the Learning From Data book by Yaser S. Abu-Mostafa, Malik Magdon-Ismail, and Hsuan-Tien Lin, and participants in the Learning From Data MOOC by Yaser S. Abu-Mostafa. No part of these contents is to be communicated or made accessible to ANY other person or entity.