ailiaSetInputBlobShape method

int ailiaSetInputBlobShape(
  1. Pointer<AILIANetwork> net,
  2. Pointer<AILIAShape> shape,
  3. int blob_idx,
  4. int version
)

Change the shape of the blob given by its index

Parameters:

  • net: network object pointer
  • shape: new shape of the blob
  • blob_idx: index referencing the blob to reshape
  • version: AILIA_SHAPE_VERSION

Returns:

In case of success, AILIA_STATUS_SUCCESS , and otherwise the coresponding error code.

This is useful to change the network input shape in a context where there are several input blobs. If blob_idx does not correspond to an input layer, AILIA_STATUS_INVALID_ARGUMENT is returned. For other related remarks, see the documentation of ailiaSetInputShape(). If dimension of shape has 5 or more, please use ailiaSetInputBlobShapeND(). This API can be call after call ailiaOpenWeighXXX().

Implementation

int ailiaSetInputBlobShape(
  ffi.Pointer<AILIANetwork> net,
  ffi.Pointer<AILIAShape> shape,
  int blob_idx,
  int version,
) {
  return _ailiaSetInputBlobShape(
    net,
    shape,
    blob_idx,
    version,
  );
}