File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -454,7 +454,7 @@ layer parse_yolo(list *options, size_params params)
454
454
}
455
455
//assert(l.outputs == params.inputs);
456
456
457
- l .show_details = option_find_int_quiet (options , "show_details" , 0 );
457
+ l .show_details = option_find_int_quiet (options , "show_details" , 1 );
458
458
l .max_delta = option_find_float_quiet (options , "max_delta" , FLT_MAX ); // set 10
459
459
char * cpc = option_find_str (options , "counters_per_class" , 0 );
460
460
l .classes_multipliers = get_classes_multipliers (cpc , classes , l .max_delta );
Original file line number Diff line number Diff line change @@ -380,6 +380,7 @@ typedef struct train_yolo_args {
380
380
int b ;
381
381
382
382
float tot_iou ;
383
+ float tot_giou_loss ;
383
384
int count ;
384
385
int class_count ;
385
386
} train_yolo_args ;
@@ -720,6 +721,7 @@ void forward_yolo_layer(const layer l, network_state state)
720
721
yolo_args [b ].b = b ;
721
722
722
723
yolo_args [b ].tot_iou = 0 ;
724
+ yolo_args [b ].tot_giou_loss = 0 ;
723
725
yolo_args [b ].count = 0 ;
724
726
yolo_args [b ].class_count = 0 ;
725
727
@@ -731,6 +733,7 @@ void forward_yolo_layer(const layer l, network_state state)
731
733
pthread_join (threads [b ], 0 );
732
734
733
735
tot_iou += yolo_args [b ].tot_iou ;
736
+ tot_giou_loss += yolo_args [b ].tot_giou_loss ;
734
737
count += yolo_args [b ].count ;
735
738
class_count += yolo_args [b ].class_count ;
736
739
}
@@ -891,7 +894,7 @@ void forward_yolo_layer(const layer l, network_state state)
891
894
892
895
float avg_iou_loss = 0 ;
893
896
* (l .cost ) = loss ;
894
- /*
897
+
895
898
// gIOU loss + MSE (objectness) loss
896
899
if (l .iou_loss == MSE ) {
897
900
* (l .cost ) = pow (mag_array (l .delta , l .outputs * l .batch ), 2 );
@@ -908,7 +911,7 @@ void forward_yolo_layer(const layer l, network_state state)
908
911
}
909
912
* (l .cost ) = avg_iou_loss + classification_loss ;
910
913
}
911
- */
914
+
912
915
913
916
loss /= l .batch ;
914
917
classification_loss /= l .batch ;
You can’t perform that action at this time.
0 commit comments