GRAIN: Exact Graph Reconstruction from Gradients

Authors: Maria Drencheva, Ivo Petrov, Maximilian Baader, Dimitar I. Dimitrov, Martin Vechev

ICLR 2025 | Venue PDF | Archive PDF | Plain Text | LLM Run Details

Reproducibility Variable Result LLM Response
Research Type Experimental We evaluate our approach on molecular, citation, and social network datasets using our novel metric. We show that GRAIN reconstructs up to 80% of all graphs exactly, significantly outperforming the baseline, which achieves up to 20% correctly positioned nodes.
Researcher Affiliation Academia Maria Drencheva1, Ivo Petrov1, Maximilian Baader2, Dimitar I. Dimitrov1,2, Martin Vechev1,2 1 INSAIT, Sofia University "St. Kliment Ohridski" 2 ETH Zurich EMAIL 1 EMAIL 2
Pseudocode Yes Algorithm 1 The GRAIN algorithm 1: function GRAIN(T0, L W , τ, f, C) 2: T L GENERATEBBS(T0, L W , τ, f) 3: T B STRUCTUREFILTER(T L , L W ) 4: return RECONSTRUCTGRAPH(T B, L W , C)
Open Source Code Yes The first gradient inversion attack on Graph Neural Networks, recovering both the graph structure and the node features. We provide an efficient implementation on Git Hub.1 1https://github.com/insait-institute/GRAIN
Open Datasets Yes We evaluate on three different types of graph data chemical data, citation and social networks. For the chemical experiments, we evaluate on molecule property prediction data, where molecules are represented as graphs and each node is a given atom. We follow the common convention to omit hydrogen atoms in the graphs. Each node is embedded by concatenating the one-hot encodings of 8 features (Xu et al., 2018; Wu et al., 2020), namely the atom type, formal charge, number of bonds, chirality, number of bonded hydrogen atoms, atomic mass, aromaticity and hybridization (Rong et al., 2020). We evaluate GRAIN on 3 well-known chemical datasets Tox21, Clintox, and BBBP, introduced by the Molecule Net benchmark (Wu et al., 2018). For the citation networks experiments, we apply GRAIN on the Cite Seer(Giles et al., 1998) dataset... Finally, for the social network experiments we use the Pokec(Rossi & Ahmed, 2015) dataset...
Dataset Splits Yes To simulate a federated learning environment, in the latter two settings we sample subgraphs of a given size from the datasets for each of the FL clients and use cluster classification objective, where each subgraph is classified as the most common class among the comprising nodes. We chose the sampling distribution: 20 graphs with 1-10 nodes, 40 graphs with 10-20 nodes, 30 graphs with 20-30 nodes, and 10 graphs with 30-40 nodes, closely mirroring the distribution of the Tox21 dataset.
Hardware Specification Yes We provide an efficient GPU imlementation, where each experiment has been run on a NVIDIA L4 Tensor Core GPU with less than 40GB of CPU memory.
Software Dependencies No The paper mentions providing an efficient GPU implementation and a GitHub link, but does not specify any particular software libraries or their version numbers (e.g., Python, PyTorch, CUDA versions).
Experiment Setup Yes Unless otherwise specified, all of our attacks are applied on 2-layer GNNs (L = 2) with a hidden embedding dimension d = 300 and a Re LU activation. For GAT experiments 2-headed attention was used (adapting GRAIN to GATs with more heads is analogous). All networks also feature a 2-layer feedforward network for performing the readout a common depth for GNNs Kipf & Welling (2016). Given the depth restrictions, we recover building blocks up to layer 2, with the first readout layer being used for the relevant filtering of the largest blocks. In Tab. 10, we show that our attack is robust with respect to changes in these architectural parameters.