ncnn下,有哪些方法可以加速推理
作者你好,请问ncnn可以输入单通道图像吗,转到ncnn下,推理速度还是没有达到要求,请问下有哪些方法可以尽可能地加速推理过程呢
可以输入单通道图像 如果想要更好的加速,设计模型的时候尽可能使用 ncnn 优化的卷积参数,比如常用的 conv1x1 conv3x3 depthwise-conv 等,不要用超大kernel(>7),dilation>1等
尝试绑定手机大核心,减少调度 ncnn::set_cpu_powersave(2); A53 可以尝试开启 bf16,net.opt.use_bf16_storage = true;
可以输入单通道图像 如果想要更好的加速,设计模型的时候尽可能使用 ncnn 优化的卷积参数,比如常用的 conv1x1 conv3x3 depthwise-conv 等,不要用超大kernel(>7),dilation>1等
尝试绑定手机大核心,减少调度 ncnn::set_cpu_powersave(2); A53 可以尝试开启 bf16,net.opt.use_bf16_storage = true;
thanks
ncnn::set_cpu_powercpu is now deprecated? Cann't use it now?
ncnn::set_cpu_powercpu is now deprecated? Cann't use it now?
there is set_cpu_powersave in cpu.h