User Tools

Site Tools


rvkde:usage

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
rvkde:usage [2008/08/19 04:08] – dirtyrvkde:usage [2008/08/19 04:21] (current) – dirty
Line 39: Line 39:
 </code> </code>
 Let's take a look at the command. Let's take a look at the command.
-^ --cv | Switch rvkde into cross-validation mode. | +^  --cv | Switch rvkde into cross-validation mode. | 
-^ --classify | Tell rvkde we want to do classification rather than regression now. | +^  --classify | Tell rvkde we want to do classification rather than regression now. | 
-^ --acc | Use [[wp>accuracy|accuracy]] as the evaluation index. | +^  --acc | Use [[wp>accuracy|accuracy]] as the evaluation index. | 
-^ -n | Do __n__-fold cross-validation. | +^  -n | Do __n__-fold cross-validation. | 
-^ -v | Followed by the dataset for cross-validation. | +^  -v | Followed by the dataset for cross-validation. | 
-^ -a | Set the range (begin, end and step) of __alpha__ values of RVKDE.  In this example, 1 is the only possible __alpha__ value. | +^  -a | Set the range (begin, end and step) of __alpha__ values of RVKDE.  In this example, 1 is the only possible __alpha__ value. | 
-^ -b | Set the range (begin, end and step) of __beta__ values of RVKDE.  In this example, the possible __beta__ values are 1, 1.5 and 2. | +^  -b | Set the range (begin, end and step) of __beta__ values of RVKDE.  In this example, the possible __beta__ values are 1, 1.5 and 2. | 
-^ --ks | Set the range (begin, end and step) of __ks__ values of RVKDE.  In this example, the possible __ks__ values are 1, 2, ... 30. | +^  --ks | Set the range (begin, end and step) of __ks__ values of RVKDE.  In this example, the possible __ks__ values are 1, 2, ... 30. | 
-^ --kt | Set the range (begin, end and step) of __kt__ values of RVKDE.  In this example, the possible __kt__ values are also 1, 2, ... 30 since the default step is 1. |+^  --kt | Set the range (begin, end and step) of __kt__ values of RVKDE.  In this example, the possible __kt__ values are also 1, 2, ... 30 since the default step is 1. |
  
   * The result looks like<code>   * The result looks like<code>
Line 56: Line 56:
 Now we have a parameter combination derived from cross-validation. Now we have a parameter combination derived from cross-validation.
   * Use these parameters to predict __satimage.scale.t__.<code>   * Use these parameters to predict __satimage.scale.t__.<code>
-rvkde-0.2.3-final/rvkde --predict --classify --acc -v rvkde-0.2.3-final/satimage.scale -V rvkde-0.2.3-final/satimage.scale.t -a 1 -b 1 --ks 8 --kt 10+rvkde-0.2.3-final/rvkde --predict --classify --acc -v rvkde-0.2.3-final/satimage.scale -V rvkde-0.2.3-final/satimage.scale.t -a 1 -b 1 --ks 8 --kt 21
 </code> </code>
 Let's take a look at the command. Let's take a look at the command.
Line 64: Line 64:
  
   * The result looks like<code>   * The result looks like<code>
-[0.916] a=1 b=1 s=8 t=10... +[0.9175] a=1 b=1 s=8 t=21... 
-</code>It indicates that RVKDE can yield a accuracy of 0.916 under this parameter combination when using __satimage.scale__ to predict __satimage.scale.t__. +</code>It indicates that RVKDE can yield a accuracy of 0.9175 under this parameter combination when using __satimage.scale__ to predict __satimage.scale.t__.
- +
  
 ====== Train, validate, and then test ====== ====== Train, validate, and then test ======
 Another common procedure for parameter selection is to create an independent validation set.  For example, you can use __satimage.scale.tr__ and __satimage.scale.val__ to do parameter selection and see how good the parameters are when applying on __satimage.scale.t__. Another common procedure for parameter selection is to create an independent validation set.  For example, you can use __satimage.scale.tr__ and __satimage.scale.val__ to do parameter selection and see how good the parameters are when applying on __satimage.scale.t__.
   * Use __satimage.scale.tr__ (as training set) and __satimage.scale.val__ (as validation set) to select the parameters.<code>   * Use __satimage.scale.tr__ (as training set) and __satimage.scale.val__ (as validation set) to select the parameters.<code>
-rvkde-0.2.3-final/rvkde --predict --classify --acc -v rvkde-0.2.3-final/satimage.scale.tr -V rvkde-0.2.3-final/satimage.scale.val -a 1,5,1 -b 1,2,0.5 --ks 1,30,1 --kt 1,30,1+rvkde-0.2.3-final/rvkde --predict --classify --acc -v rvkde-0.2.3-final/satimage.scale.tr -V rvkde-0.2.3-final/satimage.scale.val -a 1 -b 1,2,0.5 --ks 1,30,1 --kt 1,30,1
 </code> </code>
   * The result looks like<code>   * The result looks like<code>
-[0.381232] a=1 b=1.5 s=17 t=10...+[0.913599] a=1 b=1 s=8 t=23...
 </code> </code>
-  * Predict set2 with the selected model.<code> +  * Predict __satimage.scale.t__ with the selected parameters.<code> 
-rvkde/rvkde --predict --classify --f-measure -v res/tr.x5 -V res/te.x5 -a 1 -b 1.5 --ks 17 --kt 10+rvkde-0.2.3-final/rvkde --predict --classify --acc -v rvkde-0.2.3-final/satimage.scale.tr -V rvkde-0.2.3-final/satimage.scale.t -a 1 -b 1 --ks 8 --kt 23
 </code> </code>
   * The result looks like<code>   * The result looks like<code>
-[0.365651] a=1 b=1.5 s=17 t=10... +[0.917] a=1 b=1 s=8 t=23... 
-</code>It seems that the model selected is better than the previous one. +</code>It reveals that RVKDE yields very close accuracies with these two parameter selection schemes.
- +
-====== Summary of RVKDE ====== +
-Until now, you know that RVKDE has four parameters (//alpha//, //beta//, //ks//, and //kt//).  rvkde is a sophisticated machine learning package which has built-in functionalities for cross-validation and parameter-enumeration.  We will see some other parameters of rvkde in future exercises.  Of course, you could check [[http://zoro.ee.ncku.edu.tw/mbincku/rvkde/|the homepage of rvkde]] if you want to learn these facilities now. +
- +
-In addition, you learn two common model selection procedures.  In this exercise, you must try to find the best model for prediction the whole dataset, that is, F-measures of both //te.x5// and //te.x10// are good using only //tr.x5//, //va.x5//, //tr.x10//, and //va.x10//.+
rvkde/usage.1219118928.txt.gz · Last modified: by dirty