diff --git a/1-first-project/Slides/IUI_MP1_Presentation-1.pptx b/1-first-project/Slides/IUI_MP1_Presentation-1.pptx index ff4c1f6..5caf7a0 100644 Binary files a/1-first-project/Slides/IUI_MP1_Presentation-1.pptx and b/1-first-project/Slides/IUI_MP1_Presentation-1.pptx differ diff --git a/1-first-project/tdt/Hyperparameter.ipynb b/1-first-project/tdt/Hyperparameter.ipynb index 7e75a09..4e99839 100644 --- a/1-first-project/tdt/Hyperparameter.ipynb +++ b/1-first-project/tdt/Hyperparameter.ipynb @@ -3,7 +3,7 @@ { "cell_type": "code", "execution_count": 1, - "id": "cf20b791", + "id": "25685460", "metadata": {}, "outputs": [], "source": [ @@ -14,7 +14,7 @@ { "cell_type": "code", "execution_count": 2, - "id": "8114cccf", + "id": "a7b5d6ab", "metadata": {}, "outputs": [], "source": [ @@ -30,7 +30,7 @@ { "cell_type": "code", "execution_count": 3, - "id": "e1ebb5fe", + "id": "8a37e95b", "metadata": {}, "outputs": [], "source": [ @@ -52,7 +52,7 @@ { "cell_type": "code", "execution_count": 4, - "id": "e2315c69", + "id": "53e288a8", "metadata": {}, "outputs": [], "source": [ @@ -73,7 +73,7 @@ { "cell_type": "code", "execution_count": 5, - "id": "62536ff0", + "id": "0e638fb8", "metadata": {}, "outputs": [], "source": [ @@ -97,7 +97,7 @@ { "cell_type": "code", "execution_count": 6, - "id": "dd1162bb", + "id": "5080bf16", "metadata": {}, "outputs": [], "source": [ @@ -111,7 +111,7 @@ { "cell_type": "code", "execution_count": 7, - "id": "6879e37a", + "id": "41f26d6c", "metadata": {}, "outputs": [], "source": [ @@ -138,7 +138,7 @@ { "cell_type": "code", "execution_count": 8, - "id": "51f25f8e", + "id": "9bf4ea28", "metadata": {}, "outputs": [], "source": [ @@ -174,7 +174,7 @@ { "cell_type": "code", "execution_count": 9, - "id": "4ccd56dd", + "id": "fde0b3cf", "metadata": {}, "outputs": [], "source": [ @@ -197,7 +197,7 @@ { "cell_type": "code", "execution_count": 10, - "id": "4ed39aad", + "id": "9712dd25", "metadata": {}, "outputs": [], "source": [ @@ -218,7 +218,7 @@ { "cell_type": "code", "execution_count": 11, - "id": "92e85d4f", + "id": "6decb953", "metadata": {}, "outputs": [], "source": [ @@ -230,7 +230,7 @@ { "cell_type": "code", "execution_count": null, - "id": "f81aa159", + "id": "ff6a75e9", "metadata": {}, "outputs": [ { @@ -891,7 +891,55 @@ " Dense Count 1: 2\n", " Dense Neurons 1: 1800\n", " Dense Count 2: 3\n", - " Dense Neurons 2: 1200\n" + " Dense Neurons 2: 1200\n", + "Accuracy: 78.40\n", + "Testing with: Threshold: 70\n", + " Leeway: 0\n", + " Epoch: 20\n", + " Dense Count 1: 2\n", + " Dense Neurons 1: 1800\n", + " Dense Count 2: 3\n", + " Dense Neurons 2: 1800\n", + "Accuracy: 78.09\n", + "Testing with: Threshold: 70\n", + " Leeway: 0\n", + " Epoch: 20\n", + " Dense Count 1: 2\n", + " Dense Neurons 1: 1800\n", + " Dense Count 2: 3\n", + " Dense Neurons 2: 2400\n", + "Accuracy: 77.56\n", + "Testing with: Threshold: 70\n", + " Leeway: 0\n", + " Epoch: 20\n", + " Dense Count 1: 2\n", + " Dense Neurons 1: 2400\n", + " Dense Count 2: 1\n", + " Dense Neurons 2: 600\n", + "Accuracy: 78.10\n", + "Testing with: Threshold: 70\n", + " Leeway: 0\n", + " Epoch: 20\n", + " Dense Count 1: 2\n", + " Dense Neurons 1: 2400\n", + " Dense Count 2: 1\n", + " Dense Neurons 2: 1200\n", + "Accuracy: 78.49\n", + "Testing with: Threshold: 70\n", + " Leeway: 0\n", + " Epoch: 20\n", + " Dense Count 1: 2\n", + " Dense Neurons 1: 2400\n", + " Dense Count 2: 1\n", + " Dense Neurons 2: 1800\n", + "Accuracy: 78.24\n", + "Testing with: Threshold: 70\n", + " Leeway: 0\n", + " Epoch: 20\n", + " Dense Count 1: 2\n", + " Dense Neurons 1: 2400\n", + " Dense Count 2: 1\n", + " Dense Neurons 2: 2400\n" ] } ], @@ -932,7 +980,7 @@ { "cell_type": "code", "execution_count": null, - "id": "ee06862c", + "id": "89a47c03", "metadata": {}, "outputs": [], "source": [ @@ -942,7 +990,7 @@ { "cell_type": "code", "execution_count": null, - "id": "32c1ff00", + "id": "7520408c", "metadata": {}, "outputs": [], "source": [ diff --git a/1-first-project/tdt/README.md b/1-first-project/tdt/README.md index 76e3abb..d908825 100644 --- a/1-first-project/tdt/README.md +++ b/1-first-project/tdt/README.md @@ -74,6 +74,7 @@ This segment are notes dedicated to the neural network itself. ```python thresh = 100 leeway = 5 +epoch = 20 model = Sequential() @@ -102,6 +103,7 @@ Evaluate on test data ```python thresh = 75 leeway = 3 +epoch = 20 model = Sequential() @@ -130,6 +132,7 @@ Evaluate on test data ```python thresh = 10 leeway = 3 +epoch = 20 model = Sequential() @@ -153,11 +156,12 @@ Evaluate on test data 82/82 [==============================] - 0s 2ms/step - loss: 2.5231 - acc: 0.3696 ``` -#### Test4 (71.51%) +#### Test4 (69.66%) ```python thresh = 50 leeway = 3 +epoch = 20 model = Sequential() @@ -178,7 +182,249 @@ model.add(Dense(26, activation='softmax')) ``` Evaluate on test data -82/82 [==============================] - 0s 2ms/step - loss: 1.5005 - acc: 0.7151 +82/82 [==============================] - 0s 2ms/step - loss: 1.6965 - acc: 0.6966 ``` -#### Test5 () + +#### Test5 (73.13%) + +```python +thresh = 60 +leeway = 3 +epoch = 20 + +model = Sequential() + +model.add(Flatten(input_shape=X_filter[0].shape)) + +model.add(BatchNormalization()) + +model.add(Dense(1560, activation='relu')) + +model.add(Dense(750, activation='relu')) + +model.add(Dense(300, activation='relu')) + +model.add(Dense(156, activation='relu')) + +model.add(Dense(26, activation='softmax')) +``` + +``` +Evaluate on test data +82/82 [==============================] - 0s 2ms/step - loss: 1.4886 - acc: 0.7313 +``` + +#### Test6 (75.68%) + +```python +thresh = 68 +leeway = 3 +epoch = 20 + +model = Sequential() + +model.add(Flatten(input_shape=X_filter[0].shape)) + +model.add(BatchNormalization()) + +model.add(Dense(1560, activation='relu')) + +model.add(Dense(750, activation='relu')) + +model.add(Dense(300, activation='relu')) + +model.add(Dense(156, activation='relu')) + +model.add(Dense(26, activation='softmax')) +``` + +``` +Evaluate on test data +82/82 [==============================] - 0s 2ms/step - loss: 1.4227 - acc: 0.7568 +``` + +#### Test7 (76.07%) + +```python +thresh = 68 +leeway = 3 +epoch = 30 + +model = Sequential() + +model.add(Flatten(input_shape=X_filter[0].shape)) + +model.add(BatchNormalization()) + +model.add(Dense(1560, activation='relu')) + +model.add(Dense(750, activation='relu')) + +model.add(Dense(300, activation='relu')) + +model.add(Dense(156, activation='relu')) + +model.add(Dense(26, activation='softmax')) +``` + +``` +Evaluate on test data +82/82 [==============================] - 0s 2ms/step - loss: 1.5863 - acc: 0.7607 +``` + +#### Test8 (75.49%) + +```python +THRESH = 70 +LEEWAY = 3 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1800 +``` + +``` +Evaluate on test data +21/21 [==============================] - 0s 2ms/step - loss: 1.5598 - acc: 0.7684 +``` + +#### Test9 (78.15%) + +```python +THRESH = 70 +LEEWAY = 1 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1800 +``` + +``` +Evaluate on test data +21/21 [==============================] - 0s 2ms/step - loss: 1.4677 - acc: 0.7815 +``` + +#### Test10 (77.64%) + +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1900 +``` + + +#### Test11 (77.41%) + +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1800 +``` + +#### Test12 (73.90%) + +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1800 + +DENSE_COUNT = 5 +DENSE_NEURONS = 900 +``` + +#### Test13 (78.89%) + +NORM->FLAT->DENSE +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1900 +``` + +#### Test14 (79.04%) + +NORM->FLAT->DENSE +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1800 +``` + +#### Test15 (79.00%) + +NORM->FLAT->DENSE +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1700 +``` + +#### Test16 (78.69%) + +NORM->FLAT->DENSE +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 5 +DENSE_NEURONS = 1600 +``` + +#### Test17 (78.57%) + +NORM->FLAT->DENSE +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 4 +DENSE_NEURONS = 1800 +``` + +#### Test18 (78.12%) + +NORM->FLAT->DENSE +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 6 +DENSE_NEURONS = 1800 +``` + +#### Test19 (79.13%) + +NORM->FLAT->DENSE +```python +THRESH = 70 +LEEWAY = 0 +EPOCH = 30 + +DENSE_COUNT = 3 +DENSE_NEURONS = 1800 + +DENSE2_COUNT = 2 +DENSE2_NEURONS = 1200 +```