Research Article
Fast and Accurate Deep Leakage from Gradients Based on Wasserstein Distance
| | Input: : real gradient generated by real training sample . Epochs: maximum number of iterations. : learning rate. | | (1) | //Get the subscript of the last layer of negative bias | | (2) | One_Hot //Convert to One_Hot code | | (3) | //Initialize virtual data with the same dimensions as | | (4) | for to do | | (5) | //Calculating virtual gradients | | (6) | //WDCA is Algorithm 2 | | (7) | | | (8) | end for | | | Output: |
|