MLECO-2082: Adding visual wake word use case
MLECO-2083: Refactoring img_class and visual wake word

*Added source files for visual wake word
*Added tests
*Added docs
*Added new images for visual wake word demo
*Refactored common functions in img_class, visual wake word and other usecases

Change-Id: Ibd25854e19a5517f940a8d3086a5d4835fab89e9
Signed-off-by: Éanna Ó Catháin <eanna.ocathain@arm.com>
diff --git a/source/use_case/img_class/src/MainLoop.cc b/source/use_case/img_class/src/MainLoop.cc
index 61a09dd..79f6018 100644
--- a/source/use_case/img_class/src/MainLoop.cc
+++ b/source/use_case/img_class/src/MainLoop.cc
@@ -24,29 +24,6 @@
 
 using ImgClassClassifier = arm::app::Classifier;
 
-enum opcodes
-{
-    MENU_OPT_RUN_INF_NEXT = 1,       /* Run on next vector. */
-    MENU_OPT_RUN_INF_CHOSEN,         /* Run on a user provided vector index. */
-    MENU_OPT_RUN_INF_ALL,            /* Run inference on all. */
-    MENU_OPT_SHOW_MODEL_INFO,        /* Show model info. */
-    MENU_OPT_LIST_IMAGES             /* List the current baked images. */
-};
-
-static void DisplayMenu()
-{
-    printf("\n\n");
-    printf("User input required\n");
-    printf("Enter option number from:\n\n");
-    printf("  %u. Classify next image\n", MENU_OPT_RUN_INF_NEXT);
-    printf("  %u. Classify image at chosen index\n", MENU_OPT_RUN_INF_CHOSEN);
-    printf("  %u. Run classification on all images\n", MENU_OPT_RUN_INF_ALL);
-    printf("  %u. Show NN model info\n", MENU_OPT_SHOW_MODEL_INFO);
-    printf("  %u. List images\n\n", MENU_OPT_LIST_IMAGES);
-    printf("  Choice: ");
-    fflush(stdout);
-}
-
 void main_loop(hal_platform& platform)
 {
     arm::app::MobileNetModel model;  /* Model wrapper object. */
@@ -79,29 +56,29 @@
 
     /* Loop. */
     do {
-        int menuOption = MENU_OPT_RUN_INF_NEXT;
+        int menuOption = common::MENU_OPT_RUN_INF_NEXT;
         if (bUseMenu) {
-            DisplayMenu();
+            DisplayCommonMenu();
             menuOption = arm::app::ReadUserInputAsInt(platform);
             printf("\n");
         }
         switch (menuOption) {
-            case MENU_OPT_RUN_INF_NEXT:
+            case common::MENU_OPT_RUN_INF_NEXT:
                 executionSuccessful = ClassifyImageHandler(caseContext, caseContext.Get<uint32_t>("imgIndex"), false);
                 break;
-            case MENU_OPT_RUN_INF_CHOSEN: {
+            case common::MENU_OPT_RUN_INF_CHOSEN: {
                 printf("    Enter the image index [0, %d]: ", NUMBER_OF_FILES-1);
                 auto imgIndex = static_cast<uint32_t>(arm::app::ReadUserInputAsInt(platform));
                 executionSuccessful = ClassifyImageHandler(caseContext, imgIndex, false);
                 break;
             }
-            case MENU_OPT_RUN_INF_ALL:
+            case common::MENU_OPT_RUN_INF_ALL:
                 executionSuccessful = ClassifyImageHandler(caseContext, caseContext.Get<uint32_t>("imgIndex"), true);
                 break;
-            case MENU_OPT_SHOW_MODEL_INFO:
+            case common::MENU_OPT_SHOW_MODEL_INFO:
                 executionSuccessful = model.ShowModelInfoHandler();
                 break;
-            case MENU_OPT_LIST_IMAGES:
+            case common::MENU_OPT_LIST_IFM:
                 executionSuccessful = ListFilesHandler(caseContext);
                 break;
             default: