[IE CLDNN] Yolo v4 bugfix from some model (#4260)
* Winograd conv seems to cause slight error * Enable fsv16 path in case where RegionYolo exists * Prefer bfyx from RegionYolo primitive
This commit is contained in:
parent
ad21c6d3a4
commit
75eca09abd
@ -29,6 +29,7 @@
|
||||
#include "binary_convolution_inst.h"
|
||||
#include "lstm_gemm_inst.h"
|
||||
#include "generic_layer.hpp"
|
||||
#include "region_yolo_inst.h"
|
||||
|
||||
#include "kernel_selector_common.h"
|
||||
#include "kernel_selector_helper.h"
|
||||
|
@ -861,6 +861,10 @@ format layout_optimizer::get_preferred_format(program_node& node) {
|
||||
if (input_layout.format.dimension() == 5 &&
|
||||
(input_layout.data_type == data_types::f32 || input_layout.data_type == data_types::f16 ))
|
||||
expected = format::bfzyx;
|
||||
} else if (node.is_type<region_yolo>()) {
|
||||
if (_optimization_attributes.b_fs_yx_fsv16_network) {
|
||||
expected = format::bfyx;
|
||||
}
|
||||
}
|
||||
|
||||
return expected;
|
||||
|
@ -62,6 +62,7 @@
|
||||
#include "mvn_inst.h"
|
||||
#include "gemm_inst.h"
|
||||
#include "reduce_inst.h"
|
||||
#include "region_yolo_inst.h"
|
||||
#include "strided_slice_inst.h"
|
||||
#include "to_string_utils.h"
|
||||
#include "gpu/memory_gpu.h"
|
||||
@ -1219,7 +1220,8 @@ void program_impl::set_layout_optimizer_attributes(layout_optimizer& lo) {
|
||||
prim.type() != cldnn::arg_max_min::type_id() &&
|
||||
prim.type() != cldnn::mutable_data::type_id() &&
|
||||
prim.type() != cldnn::reduce::type_id() &&
|
||||
prim.type() != cldnn::strided_slice::type_id())
|
||||
prim.type() != cldnn::strided_slice::type_id() &&
|
||||
prim.type() != cldnn::region_yolo::type_id())
|
||||
can_use_fsv16 = false;
|
||||
|
||||
if (prim.type() == cldnn::quantize::type_id() &&
|
||||
|
Loading…
Reference in New Issue
Block a user