Skip to content

Bugfix: Conv/FC: Adapt code generation to handle no bias in FC and Conv

Charles Villard requested to merge silvanosky/aidge_export_cpp:conv_no_bias into dev

Context

When no bias is provided in a convolution operator, the producer is None/nullptr which may not be correctly handled everywhere.

Modified files

  • modified: aidge_export_cpp/kernels/convolution.hpp
  • modified: aidge_export_cpp/kernels/fullyconnected.hpp
  • modified: aidge_export_cpp/operators.py

Detailed major modifications

If the input[2] of a convolution or a fully connected is none. A nullptr is provided instead cast to the data type estimated from the operator output, and the code template is adapted to treat nullptr as a value of 0.

Clang-format coding style specified from aidge_core!185 And https://github.com/astral-sh/ruff

Merge request reports

Loading