deeprobust.graph.rl package

Submodules

deeprobust.graph.rl.env module

Adversarial Attacks on Neural Networks for Graph Data. ICML 2018.

https://arxiv.org/abs/1806.02371

Author’s Implementation

https://github.com/Hanjun-Dai/graph_adversarial_attack

This part of code is adopted from the author’s implementation (Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le) but modified to be integrated into the repository.

class NodeAttackEnv(features, labels, all_targets, list_action_space, classifier, num_mod=1, reward_type='binary')[source]

Node attack environment. It executes an action and then change the environment status (modify the graph).

step(actions)[source]

run actions and get rewards

deeprobust.graph.rl.nipa_config module

Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le

deeprobust.graph.rl.nipa_env module

This part of code is adopted from https://github.com/Hanjun-Dai/graph_adversarial_attack (Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le) but modified to be integrated into the repository.

class NodeInjectionEnv(features, labels, idx_train, idx_val, dict_of_lists, classifier, ratio=0.01, parallel_size=1, reward_type='binary')[source]

Node attack environment. It executes an action and then change the environment status (modify the graph).

step(actions, inference=False)[source]

run actions and get reward

deeprobust.graph.rl.nipa_nstep_replay_mem module

This part of code is adopted from https://github.com/Hanjun-Dai/graph_adversarial_attack (Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le) but modified to be integrated into the repository.

deeprobust.graph.rl.nipa_q_net_node module

Adversarial Attacks on Neural Networks for Graph Data. ICML 2018.

https://arxiv.org/abs/1806.02371

Author’s Implementation

https://github.com/Hanjun-Dai/graph_adversarial_attack

This part of code is adopted from the author’s implementation (Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le) but modified to be integrated into the repository.

class NStepQNetNode(num_steps, node_features, node_labels, list_action_space, n_injected, bilin_q=1, embed_dim=64, mlp_hidden=64, max_lv=1, gm='mean_field', device='cpu')[source]
class QNetNode(node_features, node_labels, list_action_space, n_injected, bilin_q=1, embed_dim=64, mlp_hidden=64, max_lv=1, gm='mean_field', device='cpu')[source]

deeprobust.graph.rl.nstep_replay_mem module

This part of code is adopted from https://github.com/Hanjun-Dai/graph_adversarial_attack (Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le) but modified to be integrated into the repository.

deeprobust.graph.rl.q_net_node module

Adversarial Attacks on Neural Networks for Graph Data. ICML 2018.

https://arxiv.org/abs/1806.02371

Author’s Implementation

https://github.com/Hanjun-Dai/graph_adversarial_attack

This part of code is adopted from the author’s implementation (Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le) but modified to be integrated into the repository.

class NStepQNetNode(num_steps, node_features, node_labels, list_action_space, bilin_q=1, embed_dim=64, mlp_hidden=64, max_lv=1, gm='mean_field', device='cpu')[source]
class QNetNode(node_features, node_labels, list_action_space, bilin_q=1, embed_dim=64, mlp_hidden=64, max_lv=1, gm='mean_field', device='cpu')[source]

deeprobust.graph.rl.rl_s2v_config module

Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le

deeprobust.graph.rl.rl_s2v_env module

Adversarial Attacks on Neural Networks for Graph Data. ICML 2018.

https://arxiv.org/abs/1806.02371

Author’s Implementation

https://github.com/Hanjun-Dai/graph_adversarial_attack

This part of code is adopted from the author’s implementation (Copyright (c) 2018 Dai, Hanjun and Li, Hui and Tian, Tian and Huang, Xin and Wang, Lin and Zhu, Jun and Song, Le) but modified to be integrated into the repository.

class NodeAttackEnv(features, labels, all_targets, list_action_space, classifier, num_mod=1, reward_type='binary')[source]

Node attack environment. It executes an action and then change the environment status (modify the graph).

step(actions)[source]

run actions and get rewards

Module contents