Skip to content

kernels

Classes

Functions

k_arm_convolve_s16_group_ch_mult_1

k_arm_convolve_s16_group_ch_mult_1() -> Conv2dKernelSpec

Group s16 conv2d with ch_mult==1: filter C==1 and input_ch==output_ch.

resolve_float_conv_scratch_size

resolve_float_conv_scratch_size(*, cin: int, kh: int, kw: int, elt_size: int, batch: int, in_h: int, in_w: int, out_h: int, out_w: int, stride_height: int, stride_width: int, padding_height: int, padding_width: int, dilation_height: int, dilation_width: int) -> int

Port arm_convolve_{f16,f32}_get_buffer_size route selection.

CONV_2D's float kernel specs and DEPTHWISE_CONV_2D's convert-to-convolution reroute (see depthwise_conv_2d.operator._resolve_float_scratch) both hand a [Cout, kH, kW, Cin] filter and matching input/output dims to this same generic float convolution wrapper, so one port of its route selection sizes both.

Parameters:

  • cin

    (int) –

    Input channel count.

  • kh

    (int) –

    Filter height.

  • kw

    (int) –

    Filter width.

  • elt_size

    (int) –

    Size in bytes of one input element.

  • batch

    (int) –

    Input batch count.

  • in_h

    (int) –

    Input height.

  • in_w

    (int) –

    Input width.

  • out_h

    (int) –

    Output height.

  • out_w

    (int) –

    Output width.

  • stride_height

    (int) –

    Convolution stride along height.

  • stride_width

    (int) –

    Convolution stride along width.

  • padding_height

    (int) –

    Padding along height.

  • padding_width

    (int) –

    Padding along width.

  • dilation_height

    (int) –

    Dilation along height.

  • dilation_width

    (int) –

    Dilation along width.

Returns:

  • int ( int ) –

    Bytes the wrapper asks for, zero if it runs without scratch.