- decision_tree_learning()
- find_split()
- prune()
- predict()
- ...
The evaluation functions are implemented in this file in a class named MyMetric. Check this file for imformation about
- confusion_matrix()
- accuracy()
- precision()
- recall()
- f1()
- ...
- Two files
clean.txt
andnoisy.txt
are given, in each of them there are signal data (features) for each of the seven wifis and a lable indicating which room it is.
-
2.1 Defining information gain function. Functions in
utils.py
-
2.2 find_split function and Decision tree creating. Implemented in
Decision_tree.py
- Decision tree is defined as a class with find_split and decision_tree_learning as functions in it.
- Nodes are defined as classes, also in this file.
- 3.1 n_fold_splitn. This is implemented in
utils.py
- Devides the datasets into N folds
- 3.2 Cross Validation. in
utils.py
- Do cross validation on the n folds
- 3.3 Calculating Confusion Matrix, recall, accuracy, f1. In
metric.py
- The evaluation methods are implemented.
- 4.1 Nested cross validation (option2). In
utils.py
- 4.2 Prune the tree. Pruning function implemented in
Decision_tree.py
- 4.3 Calculating confusion matrix, recall, accuracy, f1 after pruning
- The final report of this coursework has been located in
\report
directory, it containsintro_to_ML_cw1_report_final.pdf
and its LaTeX file compressed within zip.