Parcourir la source

Change metric to feature key words in some scripts

Jérôme BUISINE il y a 4 ans
Parent
commit
fab9fb5111
30 fichiers modifiés avec 180 ajouts et 185 suppressions
  1. 13 13
      README.md
  2. 7 7
      data_processing/generateAndTrain_maxwell.sh
  3. 8 8
      data_processing/generateAndTrain_maxwell_custom.sh
  4. 8 8
      data_processing/generateAndTrain_maxwell_custom_center.sh
  5. 7 7
      data_processing/generateAndTrain_maxwell_custom_filters.sh
  6. 7 7
      data_processing/generateAndTrain_maxwell_custom_filters_center.sh
  7. 7 7
      data_processing/generateAndTrain_maxwell_custom_filters_split.sh
  8. 8 8
      data_processing/generateAndTrain_maxwell_custom_split.sh
  9. 1 3
      generate/generate_data_model_corr_random.py
  10. 1 2
      generate/generate_data_model_random.py
  11. 1 2
      generate/generate_data_model_random_center.py
  12. 1 2
      generate/generate_data_model_random_split.py
  13. 6 6
      others/save_model_result_in_md_maxwell.py
  14. 3 3
      others/testModelByScene.sh
  15. 3 3
      others/testModelByScene_maxwell.sh
  16. 2 2
      run/runAll_display_data_scene.sh
  17. 6 6
      run/runAll_maxwell_area.sh
  18. 6 6
      run/runAll_maxwell_area_normed.sh
  19. 6 6
      run/runAll_maxwell_corr_custom.sh
  20. 9 9
      run/runAll_maxwell_keras.sh
  21. 6 6
      run/runAll_maxwell_keras_corr.sh
  22. 6 6
      run/runAll_maxwell_keras_corr_custom.sh
  23. 9 9
      run/runAll_maxwell_mscn_var.sh
  24. 6 6
      run/runAll_maxwell_sub_blocks_stats.sh
  25. 6 6
      run/runAll_maxwell_sub_blocks_stats_reduced.sh
  26. 7 7
      simulation/run_maxwell_simulation_corr_custom.sh
  27. 7 7
      simulation/run_maxwell_simulation_custom.sh
  28. 8 8
      simulation/run_maxwell_simulation_custom_filters.sh
  29. 8 8
      simulation/run_maxwell_simulation_filters_statistics.sh
  30. 7 7
      simulation/run_maxwell_simulation_keras_corr_custom.sh

+ 13 - 13
README.md

@@ -6,13 +6,13 @@
 pip install -r requirements.txt
 pip install -r requirements.txt
 ```
 ```
 
 
-Generate all needed data for each metrics (which requires the the whole dataset. In order to get it, you need to contact us).
+Generate all needed data for each features (which requires the the whole dataset. In order to get it, you need to contact us).
 
 
 ```bash
 ```bash
-python generate/generate_all_data.py --metric all
+python generate/generate_all_data.py --feature all
 ```
 ```
 
 
-For noise detection, many metrics are available:
+For noise detection, many features are available:
 - lab
 - lab
 - mscn
 - mscn
 - mscn_revisited
 - mscn_revisited
@@ -22,9 +22,9 @@ For noise detection, many metrics are available:
 - low_bits_6
 - low_bits_6
 - low_bits_4_shifted_2
 - low_bits_4_shifted_2
 
 
-You can also specify metric you want to compute and image step to avoid some images:
+You can also specify feature you want to compute and image step to avoid some images:
 ```bash
 ```bash
-python generate/generate_all_data.py --metric mscn --step 50
+python generate/generate_all_data.py --feature mscn --step 50
 ```
 ```
 
 
 - **step**: keep only image if image id % 50 == 0 (assumption is that keeping spaced data will let model better fit).
 - **step**: keep only image if image id % 50 == 0 (assumption is that keeping spaced data will let model better fit).
@@ -84,19 +84,19 @@ Expected values for the **choice** parameter are ['svm_model', 'ensemble_model',
 Now we have a model trained, we can use it with an image as input:
 Now we have a model trained, we can use it with an image as input:
 
 
 ```bash
 ```bash
-python prediction/predict_noisy_image_svd.py --image path/to/image.png --interval "x,x" --model saved_models/xxxxxx.joblib --metric 'lab' --mode 'svdn' --custom 'min_max_filename'
+python prediction/predict_noisy_image_svd.py --image path/to/image.png --interval "x,x" --model saved_models/xxxxxx.joblib --feature 'lab' --mode 'svdn' --custom 'min_max_filename'
 ```
 ```
 
 
-- **metric**: metric choice need to be one of the listed above.
+- **feature**: feature choice need to be one of the listed above.
 - **custom**: specify filename with custom min and max from your data interval. This file was generated using **custom** parameter of one of the **generate_data_model\*.py** script (optional parameter).
 - **custom**: specify filename with custom min and max from your data interval. This file was generated using **custom** parameter of one of the **generate_data_model\*.py** script (optional parameter).
 
 
 The model will return only 0 or 1:
 The model will return only 0 or 1:
 - 1 means noisy image is detected.
 - 1 means noisy image is detected.
 - 0 means image seem to be not noisy.
 - 0 means image seem to be not noisy.
 
 
-All SVD metrics developed need:
-- Name added into *metric_choices_labels* global array variable of **modules/utils/config.py** file.
-- A specification of how you compute the metric into *get_svd_data* method of **modules/utils/data_type.py** file.
+All SVD features developed need:
+- Name added into *feature_choices_labels* global array variable of **modules/utils/config.py** file.
+- A specification of how you compute the feature into *get_svd_data* method of **modules/utils/data_type.py** file.
 
 
 ### Predict scene using model
 ### Predict scene using model
 
 
@@ -134,7 +134,7 @@ Parameters list:
 - 2: End of interval of data from SVD to use
 - 2: End of interval of data from SVD to use
 - 3: Model we want to test
 - 3: Model we want to test
 - 4: Kind of data input used by trained model
 - 4: Kind of data input used by trained model
-- 5: Metric used by model
+- 5: feature used by model
 
 
 
 
 ### Get treshold map
 ### Get treshold map
@@ -142,7 +142,7 @@ Parameters list:
 Main objective of this project is to predict as well as a human the noise perception on a photo realistic image. Human threshold is available from training data. So a script was developed to give the predicted treshold from model and compare predicted treshold from the expected one.
 Main objective of this project is to predict as well as a human the noise perception on a photo realistic image. Human threshold is available from training data. So a script was developed to give the predicted treshold from model and compare predicted treshold from the expected one.
 
 
 ```bash
 ```bash
-python prediction/predict_seuil_expe.py --interval "x,x" --model 'saved_models/xxxx.joblib' --mode ["svd", "svdn", "svdne"] --metric ['lab', 'mscn', ...] --limit_detection xx --custom 'custom_min_max_filename'
+python prediction/predict_seuil_expe.py --interval "x,x" --model 'saved_models/xxxx.joblib' --mode ["svd", "svdn", "svdne"] --feature ['lab', 'mscn', ...] --limit_detection xx --custom 'custom_min_max_filename'
 ```
 ```
 
 
 Parameters list:
 Parameters list:
@@ -163,7 +163,7 @@ The content will be divised into two parts:
 The previous script need to already have ran to obtain and display treshold maps on this markdown file.
 The previous script need to already have ran to obtain and display treshold maps on this markdown file.
 
 
 ```bash
 ```bash
-python others/save_model_result_in_md.py --interval "xx,xx" --model saved_models/xxxx.joblib --mode ["svd", "svdn", "svdne"] --metric ['lab', 'mscn']
+python others/save_model_result_in_md.py --interval "xx,xx" --model saved_models/xxxx.joblib --mode ["svd", "svdn", "svdne"] --feature ['lab', 'mscn']
 ```
 ```
 
 
 Parameters list:
 Parameters list:

+ 7 - 7
data_processing/generateAndTrain_maxwell.sh

@@ -10,14 +10,14 @@ fi
 if [ -z "$2" ]
 if [ -z "$2" ]
   then
   then
     echo "No argument supplied"
     echo "No argument supplied"
-    echo "Need of metric information"
+    echo "Need of feature information"
     exit 1
     exit 1
 fi
 fi
 
 
 result_filename="results/models_comparisons.csv"
 result_filename="results/models_comparisons.csv"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 size=$1
 size=$1
-metric=$2
+feature=$2
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
@@ -44,8 +44,8 @@ for counter in {0..4}; do
         for mode in {"svd","svdn","svdne"}; do
         for mode in {"svd","svdn","svdne"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
+                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
 
 
                 echo $FILENAME
                 echo $FILENAME
 
 
@@ -54,11 +54,11 @@ for counter in {0..4}; do
 
 
                     echo "${MODEL_NAME} results already generated..."
                     echo "${MODEL_NAME} results already generated..."
                 else
                 else
-                    python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --renderer "maxwell" --step 40 --random 1 --percent 1
+                    python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --renderer "maxwell" --step 40 --random 1 --percent 1
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --limit_detection '2'
-                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --limit_detection '2'
+                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
                 fi
                 fi
             done
             done
         done
         done

+ 8 - 8
data_processing/generateAndTrain_maxwell_custom.sh

@@ -10,14 +10,14 @@ fi
 if [ -z "$2" ]
 if [ -z "$2" ]
   then
   then
     echo "No argument supplied"
     echo "No argument supplied"
-    echo "Need of metric information"
+    echo "Need of feature information"
     exit 1
     exit 1
 fi
 fi
 
 
 result_filename="results/models_comparisons.csv"
 result_filename="results/models_comparisons.csv"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 size=$1
 size=$1
-metric=$2
+feature=$2
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
@@ -44,9 +44,9 @@ for counter in {0..4}; do
         for mode in {"svd","svdn","svdne"}; do
         for mode in {"svd","svdn","svdne"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
                 echo $FILENAME
                 echo $FILENAME
 
 
@@ -55,11 +55,11 @@ for counter in {0..4}; do
 
 
                     echo "${MODEL_NAME} results already generated..."
                     echo "${MODEL_NAME} results already generated..."
                 else
                 else
-                    python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                    python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
-                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
+                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
                 fi
                 fi
             done
             done
         done
         done

+ 8 - 8
data_processing/generateAndTrain_maxwell_custom_center.sh

@@ -10,14 +10,14 @@ fi
 if [ -z "$2" ]
 if [ -z "$2" ]
   then
   then
     echo "No argument supplied"
     echo "No argument supplied"
-    echo "Need of metric information"
+    echo "Need of feature information"
     exit 1
     exit 1
 fi
 fi
 
 
 result_filename="results/models_comparisons.csv"
 result_filename="results/models_comparisons.csv"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 size=$1
 size=$1
-metric=$2
+feature=$2
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
@@ -44,9 +44,9 @@ for counter in {0..4}; do
         for mode in {"svd","svdn","svdne"}; do
         for mode in {"svd","svdn","svdne"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
                 echo $FILENAME
                 echo $FILENAME
 
 
@@ -55,11 +55,11 @@ for counter in {0..4}; do
 
 
                     echo "${MODEL_NAME} results already generated..."
                     echo "${MODEL_NAME} results already generated..."
                 else
                 else
-                    python generate/generate_data_model_random_center.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                    python generate/generate_data_model_random_center.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
-                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
+                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
                 fi
                 fi
             done
             done
         done
         done

+ 7 - 7
data_processing/generateAndTrain_maxwell_custom_filters.sh

@@ -10,14 +10,14 @@ fi
 if [ -z "$2" ]
 if [ -z "$2" ]
   then
   then
     echo "No argument supplied"
     echo "No argument supplied"
-    echo "Need of metric information"
+    echo "Need of feature information"
     exit 1
     exit 1
 fi
 fi
 
 
 result_filename="results/models_comparisons.csv"
 result_filename="results/models_comparisons.csv"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 size=$1
 size=$1
-metric=$2
+feature=$2
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
@@ -26,9 +26,9 @@ for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -37,10 +37,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
-                python generate/generate_data_model_random.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                python generate/generate_data_model_random.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 7 - 7
data_processing/generateAndTrain_maxwell_custom_filters_center.sh

@@ -10,14 +10,14 @@ fi
 if [ -z "$2" ]
 if [ -z "$2" ]
   then
   then
     echo "No argument supplied"
     echo "No argument supplied"
-    echo "Need of metric information"
+    echo "Need of feature information"
     exit 1
     exit 1
 fi
 fi
 
 
 result_filename="results/models_comparisons.csv"
 result_filename="results/models_comparisons.csv"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 size=$1
 size=$1
-metric=$2
+feature=$2
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
@@ -26,9 +26,9 @@ for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -37,10 +37,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
-                python generate/generate_data_model_random_center.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                python generate/generate_data_model_random_center.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 7 - 7
data_processing/generateAndTrain_maxwell_custom_filters_split.sh

@@ -10,14 +10,14 @@ fi
 if [ -z "$2" ]
 if [ -z "$2" ]
   then
   then
     echo "No argument supplied"
     echo "No argument supplied"
-    echo "Need of metric information"
+    echo "Need of feature information"
     exit 1
     exit 1
 fi
 fi
 
 
 result_filename="results/models_comparisons.csv"
 result_filename="results/models_comparisons.csv"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 size=$1
 size=$1
-metric=$2
+feature=$2
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
@@ -26,9 +26,9 @@ for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -37,10 +37,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
-                python generate/generate_data_model_random_split.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                python generate/generate_data_model_random_split.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 8 - 8
data_processing/generateAndTrain_maxwell_custom_split.sh

@@ -10,14 +10,14 @@ fi
 if [ -z "$2" ]
 if [ -z "$2" ]
   then
   then
     echo "No argument supplied"
     echo "No argument supplied"
-    echo "Need of metric information"
+    echo "Need of feature information"
     exit 1
     exit 1
 fi
 fi
 
 
 result_filename="results/models_comparisons.csv"
 result_filename="results/models_comparisons.csv"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 size=$1
 size=$1
-metric=$2
+feature=$2
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
@@ -44,9 +44,9 @@ for counter in {0..4}; do
         for mode in {"svd","svdn","svdne"}; do
         for mode in {"svd","svdn","svdne"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+                FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
                 echo $FILENAME
                 echo $FILENAME
 
 
@@ -55,11 +55,11 @@ for counter in {0..4}; do
 
 
                     echo "${MODEL_NAME} results already generated..."
                     echo "${MODEL_NAME} results already generated..."
                 else
                 else
-                    python generate/generate_data_model_random_split.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                    python generate/generate_data_model_random_split.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
-                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                    #python prediction/predict_seuil_expe_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
+                    python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
                 fi
                 fi
             done
             done
         done
         done

+ 1 - 3
generate/generate_data_model_corr_random.py

@@ -364,10 +364,8 @@ def main():
         if not os.path.exists(custom_min_max_folder):
         if not os.path.exists(custom_min_max_folder):
             os.makedirs(custom_min_max_folder)
             os.makedirs(custom_min_max_folder)
 
 
-        min_max_folder_path = os.path.join(os.path.dirname(__file__), custom_min_max_folder)
-
         min_max_current_filename = p_filename.replace(cfg.output_data_folder + '/', '').replace('deep_keras_', '') + min_max_filename
         min_max_current_filename = p_filename.replace(cfg.output_data_folder + '/', '').replace('deep_keras_', '') + min_max_filename
-        min_max_filename_path = os.path.join(min_max_folder_path, min_max_current_filename)
+        min_max_filename_path = os.path.join(custom_min_max_folder, min_max_current_filename)
 
 
         print(min_max_filename_path)
         print(min_max_filename_path)
         with open(min_max_filename_path, 'w') as f:
         with open(min_max_filename_path, 'w') as f:

+ 1 - 2
generate/generate_data_model_random.py

@@ -286,8 +286,7 @@ def main():
         if not os.path.exists(custom_min_max_folder):
         if not os.path.exists(custom_min_max_folder):
             os.makedirs(custom_min_max_folder)
             os.makedirs(custom_min_max_folder)
 
 
-        min_max_folder_path = os.path.join(os.path.dirname(__file__), custom_min_max_folder)
-        min_max_filename_path = os.path.join(min_max_folder_path, p_custom)
+        min_max_filename_path = os.path.join(custom_min_max_folder, p_custom)
 
 
         with open(min_max_filename_path, 'w') as f:
         with open(min_max_filename_path, 'w') as f:
             f.write(str(min_value_interval) + '\n')
             f.write(str(min_value_interval) + '\n')

+ 1 - 2
generate/generate_data_model_random_center.py

@@ -297,8 +297,7 @@ def main():
         if not os.path.exists(custom_min_max_folder):
         if not os.path.exists(custom_min_max_folder):
             os.makedirs(custom_min_max_folder)
             os.makedirs(custom_min_max_folder)
 
 
-        min_max_folder_path = os.path.join(os.path.dirname(__file__), custom_min_max_folder)
-        min_max_filename_path = os.path.join(min_max_folder_path, p_custom)
+        min_max_filename_path = os.path.join(custom_min_max_folder, p_custom)
 
 
         with open(min_max_filename_path, 'w') as f:
         with open(min_max_filename_path, 'w') as f:
             f.write(str(min_value_interval) + '\n')
             f.write(str(min_value_interval) + '\n')

+ 1 - 2
generate/generate_data_model_random_split.py

@@ -296,8 +296,7 @@ def main():
         if not os.path.exists(custom_min_max_folder):
         if not os.path.exists(custom_min_max_folder):
             os.makedirs(custom_min_max_folder)
             os.makedirs(custom_min_max_folder)
 
 
-        min_max_folder_path = os.path.join(os.path.dirname(__file__), custom_min_max_folder)
-        min_max_filename_path = os.path.join(min_max_folder_path, p_custom)
+        min_max_filename_path = os.path.join(custom_min_max_folder, p_custom)
 
 
         with open(min_max_filename_path, 'w') as f:
         with open(min_max_filename_path, 'w') as f:
             f.write(str(min_value_interval) + '\n')
             f.write(str(min_value_interval) + '\n')

+ 6 - 6
others/save_model_result_in_md_maxwell.py

@@ -10,7 +10,7 @@ import json
 # models imports
 # models imports
 from sklearn.utils import shuffle
 from sklearn.utils import shuffle
 from sklearn.externals import joblib
 from sklearn.externals import joblib
-from sklearn.metrics import accuracy_score, f1_score, recall_score, roc_auc_score
+from sklearn.features import accuracy_score, f1_score, recall_score, roc_auc_score
 from sklearn.model_selection import cross_val_score
 from sklearn.model_selection import cross_val_score
 from sklearn.model_selection import StratifiedKFold
 from sklearn.model_selection import StratifiedKFold
 from sklearn.model_selection import train_test_split
 from sklearn.model_selection import train_test_split
@@ -53,21 +53,21 @@ def main():
 
 
     parser.add_argument('--interval', type=str, help='Interval value to keep from svd', default='"0, 200"')
     parser.add_argument('--interval', type=str, help='Interval value to keep from svd', default='"0, 200"')
     parser.add_argument('--model', type=str, help='.joblib or .json file (sklearn or keras model)')
     parser.add_argument('--model', type=str, help='.joblib or .json file (sklearn or keras model)')
-    parser.add_argument('--metric', type=str, help='Metric data choice', choices=cfg.metric_choices_labels)
+    parser.add_argument('--feature', type=str, help='Metric data choice', choices=cfg.feature_choices_labels)
     parser.add_argument('--mode', type=str, help='Kind of normalization level wished', choices=cfg.normalization_choices)
     parser.add_argument('--mode', type=str, help='Kind of normalization level wished', choices=cfg.normalization_choices)
 
 
     args = parser.parse_args()
     args = parser.parse_args()
 
 
     p_interval   = list(map(int, args.interval.split(',')))
     p_interval   = list(map(int, args.interval.split(',')))
     p_model_file = args.model
     p_model_file = args.model
-    p_metric     = args.metric
+    p_feature    = args.feature
     p_mode       = args.mode
     p_mode       = args.mode
 
 
 
 
     # call model and get global result in scenes
     # call model and get global result in scenes
     begin, end = p_interval
     begin, end = p_interval
 
 
-    bash_cmd = "bash others/testModelByScene_maxwell.sh '" + str(begin) + "' '" + str(end) + "' '" + p_model_file + "' '" + p_mode + "' '" + p_metric + "'"
+    bash_cmd = "bash others/testModelByScene_maxwell.sh '" + str(begin) + "' '" + str(end) + "' '" + p_model_file + "' '" + p_mode + "' '" + p_feature + "'"
 
 
     print(bash_cmd)
     print(bash_cmd)
 
 
@@ -187,7 +187,7 @@ def main():
 
 
             model.compile(loss='binary_crossentropy',
             model.compile(loss='binary_crossentropy',
                         optimizer='adam',
                         optimizer='adam',
-                        metrics=['accuracy'])
+                        features=['accuracy'])
 
 
         # reshape all input data
         # reshape all input data
         x_dataset_train = np.array(x_dataset_train).reshape(len(x_dataset_train), end, 1)
         x_dataset_train = np.array(x_dataset_train).reshape(len(x_dataset_train), end, 1)
@@ -308,7 +308,7 @@ def main():
     # check if it's always the case...
     # check if it's always the case...
     nb_zones = current_data_file_path.split('_')[7]
     nb_zones = current_data_file_path.split('_')[7]
 
 
-    final_file_line = current_model_name + '; ' + str(end - begin) + '; ' + str(begin) + '; ' + str(end) + '; ' + str(nb_zones) + '; ' + p_metric + '; ' + p_mode
+    final_file_line = current_model_name + '; ' + str(end - begin) + '; ' + str(begin) + '; ' + str(end) + '; ' + str(nb_zones) + '; ' + p_feature + '; ' + p_mode
 
 
     for s in model_scores:
     for s in model_scores:
         final_file_line += '; ' + str(s)
         final_file_line += '; ' + str(s)

+ 3 - 3
others/testModelByScene.sh

@@ -31,7 +31,7 @@ fi
 if [ -z "$5" ]
 if [ -z "$5" ]
   then
   then
     echo "No fifth argument supplied"
     echo "No fifth argument supplied"
-    echo "Need of metric : 'lab', 'mscn'"
+    echo "Need of feature : 'lab', 'mscn'"
     exit 1
     exit 1
 fi
 fi
 
 
@@ -55,8 +55,8 @@ for scene in {"A","B","C","D","E","F","G","H","I"}; do
 
 
   FILENAME="data/data_${INPUT_MODE}_${INPUT_METRIC}_B${INPUT_BEGIN}_E${INPUT_END}_scene${scene}"
   FILENAME="data/data_${INPUT_MODE}_${INPUT_METRIC}_B${INPUT_BEGIN}_E${INPUT_END}_scene${scene}"
 
 
-  python generate/generate_data_model.py --output ${FILENAME} --interval "${INPUT_BEGIN},${INPUT_END}" --kind ${INPUT_MODE} --metric ${INPUT_METRIC} --scenes "${scene}" --zones "${zones}" --percent 1 --sep ";" --rowindex "0"
+  python generate/generate_data_model.py --output ${FILENAME} --interval "${INPUT_BEGIN},${INPUT_END}" --kind ${INPUT_MODE} --feature ${INPUT_METRIC} --scenes "${scene}" --zones "${zones}" --percent 1 --sep ";" --rowindex "0"
 
 
-  python prediction/prediction_scene.py --data "$FILENAME.train" --model ${INPUT_MODEL} --output "${INPUT_MODEL}_Scene${scene}_mode_${INPUT_MODE}_metric_${INPUT_METRIC}.prediction" --scene ${scene}
+  python prediction/prediction_scene.py --data "$FILENAME.train" --model ${INPUT_MODEL} --output "${INPUT_MODEL}_Scene${scene}_mode_${INPUT_MODE}_feature_${INPUT_METRIC}.prediction" --scene ${scene}
 
 
 done
 done

+ 3 - 3
others/testModelByScene_maxwell.sh

@@ -31,7 +31,7 @@ fi
 if [ -z "$5" ]
 if [ -z "$5" ]
   then
   then
     echo "No fifth argument supplied"
     echo "No fifth argument supplied"
-    echo "Need of metric : 'lab', 'mscn'"
+    echo "Need of feature : 'lab', 'mscn'"
     exit 1
     exit 1
 fi
 fi
 
 
@@ -63,8 +63,8 @@ for scene in {"A","D","G","H"}; do
 
 
   FILENAME="data/data_${INPUT_MODE}_${INPUT_METRIC}_B${INPUT_BEGIN}_E${INPUT_END}_scene${scene}"
   FILENAME="data/data_${INPUT_MODE}_${INPUT_METRIC}_B${INPUT_BEGIN}_E${INPUT_END}_scene${scene}"
 
 
-  python generate/generate_data_model.py --output ${FILENAME} --interval "${INPUT_BEGIN},${INPUT_END}" --kind ${INPUT_MODE} --metric ${INPUT_METRIC} --scenes "${scene}" --zones "${zones}" --percent 1
+  python generate/generate_data_model.py --output ${FILENAME} --interval "${INPUT_BEGIN},${INPUT_END}" --kind ${INPUT_MODE} --feature ${INPUT_METRIC} --scenes "${scene}" --zones "${zones}" --percent 1
 
 
-  python prediction/prediction_scene.py --data "$FILENAME.train" --model ${INPUT_MODEL} --output "${INPUT_MODEL}_Scene${scene}_mode_${INPUT_MODE}_metric_${INPUT_METRIC}.prediction" --scene ${scene}
+  python prediction/prediction_scene.py --data "$FILENAME.train" --model ${INPUT_MODEL} --output "${INPUT_MODEL}_Scene${scene}_mode_${INPUT_MODE}_feature_${INPUT_METRIC}.prediction" --scene ${scene}
 
 
 done
 done

+ 2 - 2
run/runAll_display_data_scene.sh

@@ -1,7 +1,7 @@
 #! bin/bash
 #! bin/bash
 
 
-for metric in {"lab","mscn","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2"}; do
+for feature in {"lab","mscn","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2"}; do
     for scene in {"A","D","G","H"}; do
     for scene in {"A","D","G","H"}; do
-        python display/display_svd_data_scene.py --scene ${scene} --interval "0,800" --indices "0, 2000" --metric ${metric} --mode svdne --step 100 --norm 1 --ylim "0, 0.01"
+        python display/display_svd_data_scene.py --scene ${scene} --interval "0,800" --indices "0, 2000" --feature ${feature} --mode svdne --step 100 --norm 1 --ylim "0, 0.01"
     done
     done
 done
 done

+ 6 - 6
run/runAll_maxwell_area.sh

@@ -12,11 +12,11 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start_index; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start_index; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 fi
 fi
 
 
-metric="sub_blocks_area"
+feature="sub_blocks_area"
 start_index=0
 start_index=0
 end_index=16
 end_index=16
 number=16
 number=16
@@ -30,8 +30,8 @@ for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
+            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -40,10 +40,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
-                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
+                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 6 - 6
run/runAll_maxwell_area_normed.sh

@@ -12,11 +12,11 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start_index; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start_index; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 fi
 fi
 
 
-metric="sub_blocks_area_normed"
+feature="sub_blocks_area_normed"
 start_index=0
 start_index=0
 end_index=16
 end_index=16
 number=16
 number=16
@@ -30,8 +30,8 @@ for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
+            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -40,10 +40,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
-                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
+                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 6 - 6
run/runAll_maxwell_corr_custom.sh

@@ -12,7 +12,7 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 
 
 fi
 fi
@@ -22,7 +22,7 @@ end_index=24
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
-metric="lab"
+feature="lab"
 
 
 for label in {"0","1"}; do
 for label in {"0","1"}; do
     for highest in {"0","1"}; do
     for highest in {"0","1"}; do
@@ -31,8 +31,8 @@ for label in {"0","1"}; do
                 for mode in {"svd","svdn","svdne"}; do
                 for mode in {"svd","svdn","svdne"}; do
                     for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
                     for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                        FILENAME="data/${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
-                        MODEL_NAME="${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
+                        FILENAME="data/${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
+                        MODEL_NAME="${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
 
 
                         echo $FILENAME
                         echo $FILENAME
 
 
@@ -41,11 +41,11 @@ for label in {"0","1"}; do
 
 
                             echo "${MODEL_NAME} results already generated..."
                             echo "${MODEL_NAME} results already generated..."
                         else
                         else
-                            python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
+                            python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
                             python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                             python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
                             # use of interval but it is not really an interval..
                             # use of interval but it is not really an interval..
-                            python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                            python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
                         fi
                         fi
                     done
                     done
                 done
                 done

+ 9 - 9
run/runAll_maxwell_keras.sh

@@ -12,7 +12,7 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 
 
 fi
 fi
@@ -23,18 +23,18 @@ end_index=24
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
 
 
-declare -A metrics_size
-metrics_size=( ["sub_blocks_stats"]="24" ["sub_blocks_stats_reduced"]="20" ["sub_blocks_area"]="16" ["sub_blocks_area_normed"]="20")
+declare -A features_size
+features_size=( ["sub_blocks_stats"]="24" ["sub_blocks_stats_reduced"]="20" ["sub_blocks_area"]="16" ["sub_blocks_area_normed"]="20")
 
 
-for metric in {"sub_blocks_stats","sub_blocks_stats_reduced","sub_blocks_area","sub_blocks_area_normed"}; do
+for feature in {"sub_blocks_stats","sub_blocks_stats_reduced","sub_blocks_area","sub_blocks_area_normed"}; do
     for nb_zones in {4,6,8,10,12}; do
     for nb_zones in {4,6,8,10,12}; do
 
 
         for mode in {"svd","svdn","svdne"}; do
         for mode in {"svd","svdn","svdne"}; do
 
 
-            end_index=${metrics_size[${metric}]}
+            end_index=${features_size[${feature}]}
 
 
-            FILENAME="data/deep_keras_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="deep_keras_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
+            FILENAME="data/deep_keras_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="deep_keras_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -44,10 +44,10 @@ for metric in {"sub_blocks_stats","sub_blocks_stats_reduced","sub_blocks_area","
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
                 echo "test"
                 echo "test"
-                #python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
+                #python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
                 #python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${end_index}
                 #python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${end_index}
 
 
-                #python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --metric ${metric}
+                #python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 6 - 6
run/runAll_maxwell_keras_corr.sh

@@ -12,7 +12,7 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 
 
 fi
 fi
@@ -22,7 +22,7 @@ end_index=24
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
-metric="lab"
+feature="lab"
 
 
 for label in {"0","1"}; do
 for label in {"0","1"}; do
     for highest in {"0","1"}; do
     for highest in {"0","1"}; do
@@ -30,8 +30,8 @@ for label in {"0","1"}; do
             for size in {5,10,15,20,25,30,35,40}; do
             for size in {5,10,15,20,25,30,35,40}; do
                 for mode in {"svd","svdn","svdne"}; do
                 for mode in {"svd","svdn","svdne"}; do
 
 
-                    FILENAME="data/deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
-                    MODEL_NAME="deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
+                    FILENAME="data/deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
+                    MODEL_NAME="deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
 
 
                     echo $FILENAME
                     echo $FILENAME
 
 
@@ -40,11 +40,11 @@ for label in {"0","1"}; do
 
 
                         echo "${MODEL_NAME} results already generated..."
                         echo "${MODEL_NAME} results already generated..."
                     else
                     else
-                        python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
+                        python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
                         python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${size}
                         python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${size}
 
 
                         # use of interval but it is not really an interval..
                         # use of interval but it is not really an interval..
-                        python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --metric ${metric}
+                        python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --feature ${feature}
                     fi
                     fi
                 done
                 done
             done
             done

+ 6 - 6
run/runAll_maxwell_keras_corr_custom.sh

@@ -12,7 +12,7 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 
 
 fi
 fi
@@ -22,7 +22,7 @@ end_index=24
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
-metric="lab"
+feature="lab"
 
 
 for label in {"0","1"}; do
 for label in {"0","1"}; do
     for highest in {"0","1"}; do
     for highest in {"0","1"}; do
@@ -30,8 +30,8 @@ for label in {"0","1"}; do
             for size in {5,10,15,20,25,30,35,40}; do
             for size in {5,10,15,20,25,30,35,40}; do
                 for mode in {"svd","svdn","svdne"}; do
                 for mode in {"svd","svdn","svdne"}; do
 
 
-                    FILENAME="data/deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
-                    MODEL_NAME="deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
+                    FILENAME="data/deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
+                    MODEL_NAME="deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
 
 
                     echo $FILENAME
                     echo $FILENAME
 
 
@@ -40,11 +40,11 @@ for label in {"0","1"}; do
 
 
                         echo "${MODEL_NAME} results already generated..."
                         echo "${MODEL_NAME} results already generated..."
                     else
                     else
-                        python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
+                        python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
                         python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${size}
                         python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${size}
 
 
                         # use of interval but it is not really an interval..
                         # use of interval but it is not really an interval..
-                        python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --metric ${metric}
+                        python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --feature ${feature}
                     fi
                     fi
                 done
                 done
             done
             done

+ 9 - 9
run/runAll_maxwell_mscn_var.sh

@@ -12,7 +12,7 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start_index; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start_index; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 fi
 fi
 
 
@@ -22,19 +22,19 @@ end_index=4
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
 
 
-declare -A metrics_size
-metrics_size=( ["mscn_var_4"]=4 ["mscn_var_16"]=16 ["mscn_var_64"]=64 ["mscn_var_16_max"]=4 ["mscn_var_64_max"]=16)
+declare -A features_size
+features_size=( ["mscn_var_4"]=4 ["mscn_var_16"]=16 ["mscn_var_64"]=64 ["mscn_var_16_max"]=4 ["mscn_var_64_max"]=16)
 
 
 for nb_zones in {4,6,8,10,12}; do
 for nb_zones in {4,6,8,10,12}; do
 
 
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
-        for metric in {"mscn_var_4","mscn_var_16","mscn_var_64","mscn_var_16_max","mscn_var_64_max"}; do
+        for feature in {"mscn_var_4","mscn_var_16","mscn_var_64","mscn_var_16_max","mscn_var_64_max"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
             for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                end_index=${metrics_size[${metric}]}
+                end_index=${features_size[${feature}]}
 
 
-                FILENAME="data/${model}_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
-                MODEL_NAME="${model}_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
+                FILENAME="data/${model}_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
+                MODEL_NAME="${model}_N${end_index}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
 
 
                 echo $FILENAME
                 echo $FILENAME
 
 
@@ -43,10 +43,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                     echo "${MODEL_NAME} results already generated..."
                     echo "${MODEL_NAME} results already generated..."
                 else
                 else
-                    python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
+                    python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                     python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                    python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                    python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
                 fi
                 fi
             done
             done
         done
         done

+ 6 - 6
run/runAll_maxwell_sub_blocks_stats.sh

@@ -12,11 +12,11 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start_index; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start_index; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 fi
 fi
 
 
-metric="sub_blocks_stats"
+feature="sub_blocks_stats"
 start_index=0
 start_index=0
 end_index=24
 end_index=24
 number=24
 number=24
@@ -30,8 +30,8 @@ for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
+            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -40,10 +40,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
-                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
+                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 6 - 6
run/runAll_maxwell_sub_blocks_stats_reduced.sh

@@ -12,11 +12,11 @@ if [ "${erased}" == "Y" ]; then
     touch ${file_path}
     touch ${file_path}
 
 
     # add of header
     # add of header
-    echo 'model_name; vector_size; start_index; end; nb_zones; metric; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
+    echo 'model_name; vector_size; start_index; end; nb_zones; feature; mode; tran_size; val_size; test_size; train_pct_size; val_pct_size; test_pct_size; train_acc; val_acc; test_acc; all_acc; F1_train; recall_train; roc_auc_train; F1_val; recall_val; roc_auc_val; F1_test; recall_test; roc_auc_test; F1_all; recall_all; roc_auc_all;' >> ${file_path}
 
 
 fi
 fi
 
 
-metric="sub_blocks_stats_reduced"
+feature="sub_blocks_stats_reduced"
 start_index=0
 start_index=0
 end_index=24
 end_index=24
 number=24
 number=24
@@ -30,8 +30,8 @@ for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${metric}_${mode}"
+            FILENAME="data/${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${number}_B${start_index}_E${end_index}_nb_zones_${nb_zones}_${feature}_${mode}"
 
 
             echo $FILENAME
             echo $FILENAME
 
 
@@ -40,10 +40,10 @@ for nb_zones in {4,6,8,10,12}; do
 
 
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
-                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
+                python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start_index},${end_index}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "${start_index},${end_index}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 7 - 7
simulation/run_maxwell_simulation_corr_custom.sh

@@ -8,7 +8,7 @@ size=24
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
-metric="lab"
+feature="lab"
 
 
 for label in {"0","1"}; do
 for label in {"0","1"}; do
     for highest in {"0","1"}; do
     for highest in {"0","1"}; do
@@ -17,22 +17,22 @@ for label in {"0","1"}; do
                 for mode in {"svd","svdn","svdne"}; do
                 for mode in {"svd","svdn","svdne"}; do
                     for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
                     for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                            FILENAME="data/${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
-                            MODEL_NAME="${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
-                            CUSTOM_MIN_MAX_FILENAME="${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}_min_max_values"
+                            FILENAME="data/${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
+                            MODEL_NAME="${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
+                            CUSTOM_MIN_MAX_FILENAME="${model}_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}_min_max_values"
 
 
                             echo ${MODEL_NAME}
                             echo ${MODEL_NAME}
 
 
                         if grep -xq "${MODEL_NAME}" "${simulate_models}"; then
                         if grep -xq "${MODEL_NAME}" "${simulate_models}"; then
                             echo "Run simulation for model ${MODEL_NAME}"
                             echo "Run simulation for model ${MODEL_NAME}"
 
 
-                            python generate/generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
+                            python generate/generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
 
 
                             python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                             python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                            python prediction/prediction/predict_seuil_expe_maxwell_curve.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
+                            python prediction/prediction/predict_seuil_expe_maxwell_curve.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
 
 
-                            python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                            python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
 
 
                         fi
                         fi
                     done
                     done

+ 7 - 7
simulation/run_maxwell_simulation_custom.sh

@@ -8,7 +8,7 @@ scenes="A, D, G, H"
 VECTOR_SIZE=200
 VECTOR_SIZE=200
 
 
 for size in {"4","8","16","26","32","40"}; do
 for size in {"4","8","16","26","32","40"}; do
-    for metric in {"lab","mscn","mscn_revisited","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2","ica_diff","ipca_diff","svd_trunc_diff","svd_reconstruct"}; do
+    for feature in {"lab","mscn","mscn_revisited","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2","ica_diff","ipca_diff","svd_trunc_diff","svd_reconstruct"}; do
 
 
         half=$(($size/2))
         half=$(($size/2))
         start=-$half
         start=-$half
@@ -31,21 +31,21 @@ for size in {"4","8","16","26","32","40"}; do
                  for mode in {"svd","svdn","svdne"}; do
                  for mode in {"svd","svdn","svdne"}; do
                      for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
                      for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                        FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                        MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}"
-                        CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+                        FILENAME="data/${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                        MODEL_NAME="${model}_N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}"
+                        CUSTOM_MIN_MAX_FILENAME="N${size}_B${start}_E${end}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
                         if grep -xq "${MODEL_NAME}" "${simulate_models}"; then
                         if grep -xq "${MODEL_NAME}" "${simulate_models}"; then
                             echo "Run simulation for model ${MODEL_NAME}"
                             echo "Run simulation for model ${MODEL_NAME}"
 
 
                             # by default regenerate model
                             # by default regenerate model
-                            python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                            python generate/generate_data_model_random.py --output ${FILENAME} --interval "${start},${end}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
 
 
                             python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                             python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                            python prediction/predict_seuil_expe_maxwell_curve.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
+                            python prediction/predict_seuil_expe_maxwell_curve.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
 
 
-                            python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                            python others/save_model_result_in_md_maxwell.py --interval "${start},${end}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
 
 
                         fi
                         fi
                     done
                     done

+ 8 - 8
simulation/run_maxwell_simulation_custom_filters.sh

@@ -12,16 +12,16 @@ scenes="A, D, G, H"
 
 
 for size in {"4","8","16","26","32","40"}; do
 for size in {"4","8","16","26","32","40"}; do
 
 
-    # for metric in {"lab","mscn","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2","ica_diff","svd_trunc_diff","ipca_diff","svd_reconstruct"}; do
-    for metric in {"highest_sv_std_filters_full","lowest_sv_std_filters_full"}; do
+    # for feature in {"lab","mscn","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2","ica_diff","svd_trunc_diff","ipca_diff","svd_reconstruct"}; do
+    for feature in {"highest_sv_std_filters_full","lowest_sv_std_filters_full"}; do
 
 
         for nb_zones in {4,6,8,10,12}; do
         for nb_zones in {4,6,8,10,12}; do
             for mode in {"svd","svdn","svdne"}; do
             for mode in {"svd","svdn","svdne"}; do
                 for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
                 for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-                    FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-                    MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-                    CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+                    FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+                    MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+                    CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
                     echo $MODEL_NAME
                     echo $MODEL_NAME
 
 
@@ -31,12 +31,12 @@ for size in {"4","8","16","26","32","40"}; do
                         echo "${MODEL_NAME} results already generated..."
                         echo "${MODEL_NAME} results already generated..."
                     else
                     else
                         # Use of already generated model
                         # Use of already generated model
-                        # python generate/generate_data_model_random.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                        # python generate/generate_data_model_random.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                         # python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                         # python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                        python prediction/predict_seuil_expe_maxwell_curve.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
+                        python prediction/predict_seuil_expe_maxwell_curve.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
 
 
-                        python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                        python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
                     fi
                     fi
                 done
                 done
             done
             done

+ 8 - 8
simulation/run_maxwell_simulation_filters_statistics.sh

@@ -8,16 +8,16 @@ scenes="A, D, G, H"
 
 
 size="26"
 size="26"
 
 
-# for metric in {"lab","mscn","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2","ica_diff","svd_trunc_diff","ipca_diff","svd_reconstruct"}; do
-metric="filters_statistics"
+# for feature in {"lab","mscn","low_bits_2","low_bits_3","low_bits_4","low_bits_5","low_bits_6","low_bits_4_shifted_2","ica_diff","svd_trunc_diff","ipca_diff","svd_reconstruct"}; do
+feature="filters_statistics"
 
 
 for nb_zones in {4,6,8,10,12}; do
 for nb_zones in {4,6,8,10,12}; do
     for mode in {"svd","svdn","svdne"}; do
     for mode in {"svd","svdn","svdne"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
         for model in {"svm_model","ensemble_model","ensemble_model_v2"}; do
 
 
-            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}"
-            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_min_max"
+            FILENAME="data/${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            MODEL_NAME="${model}_N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}"
+            CUSTOM_MIN_MAX_FILENAME="N${size}_B0_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_min_max"
 
 
             echo $MODEL_NAME
             echo $MODEL_NAME
 
 
@@ -27,12 +27,12 @@ for nb_zones in {4,6,8,10,12}; do
                 echo "${MODEL_NAME} results already generated..."
                 echo "${MODEL_NAME} results already generated..."
             else
             else
                 # Use of already generated model
                 # Use of already generated model
-                # python generate/generate_data_model_random.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
+                # python generate/generate_data_model_random.py --output ${FILENAME} --interval "0,${size}" --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 40 --random 1 --custom ${CUSTOM_MIN_MAX_FILENAME}
                 # python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
                 # python train_model.py --data ${FILENAME} --output ${MODEL_NAME} --choice ${model}
 
 
-                python prediction/predict_seuil_expe_maxwell_curve.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric} --custom ${CUSTOM_MIN_MAX_FILENAME}
+                python prediction/predict_seuil_expe_maxwell_curve.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature} --custom ${CUSTOM_MIN_MAX_FILENAME}
 
 
-                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --metric ${metric}
+                python others/save_model_result_in_md_maxwell.py --interval "0,${size}" --model "saved_models/${MODEL_NAME}.joblib" --mode "${mode}" --feature ${feature}
             fi
             fi
         done
         done
     done
     done

+ 7 - 7
simulation/run_maxwell_simulation_keras_corr_custom.sh

@@ -8,7 +8,7 @@ size=24
 
 
 # selection of four scenes (only maxwell)
 # selection of four scenes (only maxwell)
 scenes="A, D, G, H"
 scenes="A, D, G, H"
-metric="lab"
+feature="lab"
 
 
 for label in {"0","1"}; do
 for label in {"0","1"}; do
     for highest in {"0","1"}; do
     for highest in {"0","1"}; do
@@ -16,24 +16,24 @@ for label in {"0","1"}; do
             for size in {5,10,15,20,25,30,35,40}; do
             for size in {5,10,15,20,25,30,35,40}; do
                 for mode in {"svd","svdn","svdne"}; do
                 for mode in {"svd","svdn","svdne"}; do
 
 
-                    FILENAME="data/deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
-                    MODEL_NAME="deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}"
+                    FILENAME="data/deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
+                    MODEL_NAME="deep_keras_N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}"
 
 
 
 
-                    CUSTOM_MIN_MAX_FILENAME="N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${metric}_${mode}_corr_L${label}_H${highest}_min_max_values"
+                    CUSTOM_MIN_MAX_FILENAME="N${size}_B${start_index}_E${size}_nb_zones_${nb_zones}_${feature}_${mode}_corr_L${label}_H${highest}_min_max_values"
 
 
                     echo ${MODEL_NAME}
                     echo ${MODEL_NAME}
 
 
                     if grep -xq "${MODEL_NAME}" "${simulate_models}"; then
                     if grep -xq "${MODEL_NAME}" "${simulate_models}"; then
                         echo "Run simulation for model ${MODEL_NAME}"
                         echo "Run simulation for model ${MODEL_NAME}"
 
 
-                        python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --metric ${metric} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
+                        python generate/generate_data_model_corr_random.py --output ${FILENAME} --n ${size} --highest ${highest} --label ${label} --kind ${mode} --feature ${feature} --scenes "${scenes}" --nb_zones "${nb_zones}" --percent 1 --renderer "maxwell" --step 10 --random 1 --custom 1
 
 
                         python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${size}
                         python deep_network_keras_svd.py --data ${FILENAME} --output ${MODEL_NAME} --size ${size}
 
 
-                        python prediction/predict_seuil_expe_maxwell_curve.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --metric ${metric} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
+                        python prediction/predict_seuil_expe_maxwell_curve.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --feature ${feature} --limit_detection '2' --custom ${CUSTOM_MIN_MAX_FILENAME}
 
 
-                        python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --metric ${metric}
+                        python others/save_model_result_in_md_maxwell.py --interval "${start_index},${size}" --model "saved_models/${MODEL_NAME}.json" --mode "${mode}" --feature ${feature}
 
 
                     fi
                     fi
                 done
                 done