|
|
|
@@ -268,25 +268,7 @@ int Convolution_riscv::forward(const Mat& bottom_blob, Mat& top_blob, const Opti |
|
|
|
|
|
|
|
if (bottom_blob.dims != 3) |
|
|
|
{ |
|
|
|
Mat bottom_blob_unpacked = bottom_blob; |
|
|
|
if (bottom_blob.elempack != 1) |
|
|
|
{ |
|
|
|
Option opt_pack1 = opt; |
|
|
|
opt_pack1.blob_allocator = opt.workspace_allocator; |
|
|
|
|
|
|
|
convert_packing(bottom_blob, bottom_blob_unpacked, 1, opt_pack1); |
|
|
|
} |
|
|
|
|
|
|
|
Mat bottom_blob_unpacked_fp32 = bottom_blob_unpacked; |
|
|
|
if (bottom_blob_unpacked.elembits() == 16) |
|
|
|
{ |
|
|
|
Option opt_pack1 = opt; |
|
|
|
opt_pack1.blob_allocator = opt.workspace_allocator; |
|
|
|
|
|
|
|
cast_float16_to_float32(bottom_blob_unpacked, bottom_blob_unpacked_fp32, opt_pack1); |
|
|
|
} |
|
|
|
|
|
|
|
return Convolution::forward(bottom_blob_unpacked_fp32, top_blob, opt); |
|
|
|
return Convolution::forward(bottom_blob, top_blob, opt); |
|
|
|
} |
|
|
|
|
|
|
|
int elembits = bottom_blob.elembits(); |
|
|
|
|