[object Object][object Object]

[object Object]undefined
[object Object]
  • Description: Computes the size of each kernel based on the input outputSize, performs 3D max pooling on the input self, and outputs the pooled value outputOut and index indicesOut. The difference between aclnnAdaptiveMaxPool3d and aclnnMaxPool3d is that you only need to specify the outputSize size and divide the pooling region based on the outputSize size.

  • Formula: N (Batch) represents the batch size, C (Channels) represents the number of feature map channels, D (Depth) represents the feature map depth, H (Height) represents the feature map height, and W (Width) represents the feature map width. For the input self with shape [N,C,D,H,W][N, C, D, H, W] and outputSize with shape [Do,Ho,Wo][D_o, H_o, W_o], the output has shape [N,C,Do,Ho,Wo][N, C, D_o, H_o, W_o] and the indices have shape [N,C,Do,Ho,Wo][N, C, D_o, H_o, W_o]. The calculation formula for each element (l,m,n)(l, m, n) in the corresponding tensor is as follows:

    Dleftl=(lD)/DoD^{l}_{left} = \lfloor(l*D)/D_o\rfloor Drightl=((l+1)D)/DoD^{l}_{right} = \lceil((l+1)*D)/D_o\rceil Hleftm=(mH)/HoH^{m}_{left} = \lfloor(m*H)/H_o\rfloor Hrightm=((m+1)H)/HoH^{m}_{right} = \lceil((m+1)*H)/H_o\rceil Wleftn=(nW)/WoW^{n}_{left} = \lfloor(n*W)/W_o\rfloor Wrightn=((n+1)W)/WoW^{n}_{right} = \lceil((n+1)*W)/W_o\rceil output(N,C,l,m,n)=maxi[Dleftl,Drightl],j[Hleftm,Hrightm],k[Wleftn,Wrightn]input(N,C,i,j,k)output(N,C,l,m,n)=\underset {i \in [D^{l}_{left}, D^{l}_{right}],j\in [H^m_{left},H^m_{right}], k \in [W^n_{left},W^n_{right}] }{max} input(N,C,i,j,k) indices(N,C,l,m,n)=argmaxi[Dleftl,Drightl],j[Hleftm,Hrightm],k[Wleftn,Wrightn]input(N,C,i,j,k)indices(N,C,l,m,n)=\underset {i \in [D^{l}_{left}, D^{l}_{right}],j\in [H^m_{left},H^m_{right}], k \in [W^n_{left},W^n_{right}] }{argmax} input(N,C,i,j,k)
[object Object]

Each operator has calls. First, aclnnAdaptiveMaxPool3dGetWorkspaceSize is called to obtain the workspace size required for computation and the executor that contains the operator computation process. Then, aclnnAdaptiveMaxPool3d is called to perform computation.

[object Object]
[object Object]
[object Object]
  • Parameters:

    [object Object]
    • For the [object Object]Atlas A3 training products/Atlas A3 inference products[object Object] and [object Object]Atlas A2 training products/Atlas A2 inference products[object Object], the data type of the [object Object] parameter does not support INT64.
  • Returns:

    [object Object]: status code. For details, see .

    The first-phase API implements input parameter verification. The following errors may be thrown.

    [object Object]
[object Object]
  • Parameters:

    [object Object]
  • Returns:

    [object Object]: status code. For details, see .

[object Object]
  • Deterministic compute:

    • aclnnAdaptiveMaxPool3d defaults to a deterministic implementation.
  • Shape description:

    • self.shape = (N, C, Din, Hin, Win)
    • outputSize = [Dout, Hout, Wout]
    • outputOut.shape = (N, C, Dout, Hout, Wout)
    • indicesOut.shape = (N, C, Dout, Hout, Wout)
[object Object]

The following example is for reference only. For details, see .

[object Object]