我要评分
获取效率
正确性
完整性
易理解

Calling a Matrix Arithmetic Operator

Matrix arithmetic operators support two-party operations. The two compute nodes are set to compute nodes 0 and 1.

  1. Configure KCAL settings, such as communication APIs and node information, through DataGuard APIs.
  2. Initialize the function group for matrix arithmetic operators. This function group includes all the public APIs for matrix arithmetic operators.
  3. Apply the settings to KCAL during initialization.
  4. Set the information about all nodes.
  5. Exchange seed information.
    Compute node 0:
    1. Call the secret sharing API twice: once for receiving data shares of compute node 1, and again for splitting data of compute node 0 itself into shares and sending to compute node 1 the share size of compute node 0.
    2. Concatenate the data shares of both nodes in a specific order as input parameters for the calculate API.
    3. Call the calculate API to perform calculation based on the input operator type.
    4. Call the reveal API to obtain the final calculation output.
    Compute node 1:
    1. Call the secret sharing API twice: once for splitting data of compute node 1 itself into shares and sending the data shares to compute node 0, and again for receiving the share size of compute node 0.
    2. Use all the data shares as the input parameters of the calculate API.
    3. Call the calculate API to perform calculation based on the input operator type.
    4. Call the reveal API to obtain the final calculation output.