Change Example orthofoto
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
+509
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -12,7 +12,7 @@
|
||||
"import json\n",
|
||||
"import cv2\n",
|
||||
"import sys\n",
|
||||
"sys.path += [os.path.abspath('keras-yolo3-master')]\n",
|
||||
"sys.path += [os.path.abspath('../keras-yolo3-master')]\n",
|
||||
"\n",
|
||||
"from utils.utils import get_yolo_boxes, makedirs\n",
|
||||
"from utils.bbox import draw_boxes\n",
|
||||
@@ -38,7 +38,7 @@
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"input_path = 'images/Mision 23_DJI_0061.jpg' \n",
|
||||
"input_path = '../images/Mision 23_DJI_0061.jpg' \n",
|
||||
"#output_path = 'Result_Complete_Example/'\n",
|
||||
"#makedirs(output_path)"
|
||||
]
|
||||
+3
-3
@@ -12,7 +12,7 @@
|
||||
"import json\n",
|
||||
"import cv2\n",
|
||||
"import sys\n",
|
||||
"sys.path += [os.path.abspath('keras-yolo3-master')]\n",
|
||||
"sys.path += [os.path.abspath('../keras-yolo3-master')]\n",
|
||||
"\n",
|
||||
"from utils.utils import get_yolo_boxes, makedirs\n",
|
||||
"from utils.bbox import draw_boxes\n",
|
||||
@@ -38,8 +38,8 @@
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"input_path = '100_Example/'\n",
|
||||
"output_path = 'Result_Complete_Example/'\n",
|
||||
"input_path = '../100_Example/'\n",
|
||||
"output_path = '../Result_Complete_Example/'\n",
|
||||
"makedirs(output_path)"
|
||||
]
|
||||
},
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -20,7 +20,7 @@
|
||||
"import json\n",
|
||||
"import cv2\n",
|
||||
"import sys\n",
|
||||
"sys.path += [os.path.abspath('keras-yolo3-master')]\n",
|
||||
"sys.path += [os.path.abspath('../keras-yolo3-master')]\n",
|
||||
"\n",
|
||||
"from utils.utils import get_yolo_boxes, makedirs\n",
|
||||
"from utils.bbox import draw_boxes\n",
|
||||
@@ -129,7 +129,7 @@
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"image_path = 'images/Mision 23_DJI_0061.jpg' \n",
|
||||
"image_path = '../images/Mision 23_DJI_0061.jpg' \n",
|
||||
"\n",
|
||||
"\n",
|
||||
"image = cv2.imread(image_path)\n",
|
||||
@@ -251,7 +251,7 @@
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"image_path = 'images/Mision 23_DJI_0061.jpg' \n",
|
||||
"image_path = '../images/Mision 23_DJI_0061.jpg' \n",
|
||||
"\n",
|
||||
"\n",
|
||||
"image = cv2.imread(image_path)\n",
|
||||
@@ -374,7 +374,7 @@
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"image_path = 'images/Mision 23_DJI_0061.jpg' \n",
|
||||
"image_path = '../images/Mision 23_DJI_0061.jpg' \n",
|
||||
"\n",
|
||||
"\n",
|
||||
"image = cv2.imread(image_path)\n",
|
||||
@@ -489,7 +489,7 @@
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"image_path = 'images/Mision 23_DJI_0061.jpg' \n",
|
||||
"image_path = '../images/Mision 23_DJI_0061.jpg' \n",
|
||||
"\n",
|
||||
"\n",
|
||||
"image = cv2.imread(image_path)\n",
|
||||
@@ -571,7 +571,7 @@
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"image_path = 'images/Mision 23_DJI_0061.jpg' \n",
|
||||
"image_path = '../images/Mision 23_DJI_0061.jpg' \n",
|
||||
"\n",
|
||||
"\n",
|
||||
"image = cv2.imread(image_path)\n",
|
||||
File diff suppressed because one or more lines are too long
+49
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["1"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_S/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_S/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_1/experimento_fault_1_gpu.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-4,
|
||||
"nb_epochs": 200,
|
||||
"warmup_epochs": 15,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0,1",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../log_experimento_fault_gpu",
|
||||
"saved_weights_name": "../Result_yolo3_fault_1/yolo3_full_fault_1.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_S/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_S/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_1/val_fault_1.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_S/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_S/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_1/test_fault_1.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["1"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_S/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_S/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_1/experimento_fault_1_gpu.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-4,
|
||||
"nb_epochs": 200,
|
||||
"warmup_epochs": 15,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0,1",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../log_experimento_fault_gpu",
|
||||
"saved_weights_name": "../Result_yolo3_fault_1/yolo3_full_fault_1.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_S/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_S/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_1/val_fault_1.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_S/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_S/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_1/test_fault_1.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["2"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_H/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_H/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_2/experimento_fault_2_gpu.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-4,
|
||||
"nb_epochs": 200,
|
||||
"warmup_epochs": 10,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../Result_yolo3_fault_2/log_experimento_fault_gpu_2",
|
||||
"saved_weights_name": "../Result_yolo3_fault_2/yolo3_full_fault_2.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_H/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_H/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_2/val_fault_2.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_H/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_H/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_2/test_fault_2.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["2"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_H/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_H/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_2/experimento_fault_2_gpu.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-4,
|
||||
"nb_epochs": 200,
|
||||
"warmup_epochs": 10,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../Result_yolo3_fault_2/log_experimento_fault_gpu_2",
|
||||
"saved_weights_name": "../Result_yolo3_fault_2/yolo3_full_fault_2.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_H/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_H/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_2/val_fault_2.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_H/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_H/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_2/test_fault_2.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["4"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_D/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_D/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_4/Result_yolo3_fault_4.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-4,
|
||||
"nb_epochs": 500,
|
||||
"warmup_epochs": 15,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0,1",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../log_experimento_fault_gpu",
|
||||
"saved_weights_name": "../Result_yolo3_fault_4/yolo3_full_fault_4.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_D/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_D/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_4/Result_yolo3_fault_4.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_D/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_D/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_4/Result_yolo3_fault_4.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["4"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_D/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_D/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_4/Result_yolo3_fault_4.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-4,
|
||||
"nb_epochs": 500,
|
||||
"warmup_epochs": 15,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0,1",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../log_experimento_fault_gpu",
|
||||
"saved_weights_name": "../Result_yolo3_fault_4/yolo3_full_fault_4.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_D/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_D/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_4/Result_yolo3_fault_4.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_D/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_D/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_fault_4/Result_yolo3_fault_4.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["panel"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_A/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_A/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_panel/train_panel.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-3,
|
||||
"nb_epochs": 500,
|
||||
"warmup_epochs": 15,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0,1",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../Result_yolo3_panel/log_experimento_panel_gpu",
|
||||
"saved_weights_name": "../Result_yolo3_panel/yolo3_full_panel.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_A/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_A/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_panel/val_panel.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_A/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_A/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_panel/test_panel.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"model" : {
|
||||
"min_input_size": 400,
|
||||
"max_input_size": 400,
|
||||
"anchors": [5,7, 10,14, 15, 15, 26,32, 45,119, 54,18, 94,59, 109,183, 200,21],
|
||||
"labels": ["panel"],
|
||||
"backend": "../keras-yolo3-master/full_yolo_backend.h5"
|
||||
},
|
||||
|
||||
"train": {
|
||||
"train_image_folder": "../Train&Test_A/Train/images/",
|
||||
"train_annot_folder": "../Train&Test_A/Train/anns/",
|
||||
"cache_name": "../Result_yolo3_panel/train_panel.pkl",
|
||||
|
||||
"train_times": 1,
|
||||
|
||||
"batch_size": 2,
|
||||
"learning_rate": 1e-3,
|
||||
"nb_epochs": 500,
|
||||
"warmup_epochs": 15,
|
||||
"ignore_thresh": 0.5,
|
||||
"gpus": "0,1",
|
||||
|
||||
"grid_scales": [1,1,1],
|
||||
"obj_scale": 5,
|
||||
"noobj_scale": 1,
|
||||
"xywh_scale": 1,
|
||||
"class_scale": 1,
|
||||
|
||||
"tensorboard_dir": "../Result_yolo3_panel/log_experimento_panel_gpu",
|
||||
"saved_weights_name": "../Result_yolo3_panel/yolo3_full_panel.h5",
|
||||
"debug": true
|
||||
},
|
||||
|
||||
"valid": {
|
||||
"valid_image_folder": "../Train&Test_A/Test/images/",
|
||||
"valid_annot_folder": "../Train&Test_A/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_panel/val_panel.pkl",
|
||||
|
||||
"valid_times": 1
|
||||
},
|
||||
"test": {
|
||||
"test_image_folder": "../Train&Test_A/Test/images/",
|
||||
"test_annot_folder": "../Train&Test_A/Test/anns/",
|
||||
"cache_name": "../Result_yolo3_panel/test_panel.pkl",
|
||||
|
||||
"test_times": 1
|
||||
}
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
@@ -263,5 +263,5 @@ Before sending your pull requests, make sure you followed this list.
|
||||
|
||||
# Example to use trained model
|
||||
|
||||
In ['Example_Prediction'](Example_prediction.ipynb) this is the example of how to implement an already trained model, it can be modified to change the model you have to use and the image in which you want to detect faults.
|
||||
In ['Example_Prediction_AllInOne'](Example Detection AllInOne.ipynb) this is the example of how implement all trained model, you can use this code for predict a folder of images and have a output image with detection boxes.
|
||||
In ['Example_Prediction'](Code_Example/Example_prediction.ipynb) this is the example of how to implement an already trained model, it can be modified to change the model you have to use and the image in which you want to detect faults.
|
||||
In ['Example_Prediction_AllInOne'](Code_Example/Example Detection AllInOne.ipynb) this is the example of how implement all trained model, you can use this code for predict a folder of images and have a output image with detection boxes.
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
ls images | sed -e 's/\..*$//' > train.txt
|
||||
Reference in New Issue
Block a user