-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathREADME
71 lines (42 loc) · 3.25 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
STUDENT ID NUMBERS and Names
21579617 - Mark Rogers
20206553 - James Long
22270627 - Siqi Wu
==== FOLDER DESCRIPTIONS
=== 1) code - all code written for this project
=== 2) data - data files used by code
=== 3) outline - the outline we submitted as part of hw2
=== 4) papers - a few papers we read for this project (just .pdfs)
=== 5) report - .tex and some .pdf for final report to be submitted
- final report is in report/ms.pdf
=== 6) results - output of code moved / stored here
============
============ MORE ON THE CODE FOLDER
============
==== contains code for fitting path algorithm for interval SVM
==== see folder: code/svmIntervalPath
Matlab code: the svmIntervalPath package
svmInterval.m: matlab function to fit an interval SVM by calling cvx functions.
svmIntervalPath.m: matlab function to compute the entire regularization path.
svmIntervalInit.m: matlab function to compute the initialization configurations.
svmIntervalFindNext0.m: matlab function to find the initial break point lambda.
svmIntervalFindNext.m: matlab function to iteratively find the next events.
vline.m: a convenient matlab function to plot verticle lines.
=== see folder ExamplePathPlots
ExamplePathPlots contains three plots that are relevant in our simulated example in the report: alphaPath.pdf, beta0Path.pdf and betaPath.pdf
==== Files for implementing ordinary "brute force" version of interval SVM
CODE FOR CROSS VALIDATION FRAMEWORK:
svm.m: Takes as input a training set of interval data, training labels, a testing set of interval data, testing labels, and fixed hyperparameters lambda and rho and outputs the classification error and the model parameters beta and beta0.
xval.m: Partitions data into disjoint blocks and performs cross-validation to compute an estimate of the expected loss of the SVM with designated hyperparameters and interval dataset.
computeResults.m: Takes as input an interval dataset and produces a file for each designated (lambda,rho) hyperparameter pair.
batch.m: Script that calls driver function computeResults.m with indicate dataset and hyperparameters.
CODE FOR SUMMARIZING RESULTS:
collectResults.m: Aggregates file outputs from computeResults.m to yield two matrices loss_values and L0_norm_b, which summarize loss values and L0 norm values as a function of the hyperparameters lambda and rho. Also produces plots of all results.
collect.m: Script that calls driver function collectResults.m with indicated directory of files produced by computeResults.m
analyze_features.m: Takes as input summary file and outputs a text file containing features paired with the absolute values of their weights. This is used to determine which features are important.
features.m: Script that calls driver function analyze_features.m with indicated summary results filename
HELPER FUNCTIONS:
getParams.m: Takes as input vectors of hyperparameters Lambda, Rho, and C and produces cell array Params, where Params{i,j} = [Lambda(i) Rho(j)]
quantile_ranking.m: Normalizes data via the quantile ranking method
preprocess_data.m: Removes zeros that are either all zeros or contain NaN's and then applies quantile ranking
mytiedrank.m: Helper function to quantile_ranking.m which simply ranks elements of a vector and assigns equal ranks in the event of ties