jaxels20 / link-predection-on-dda

MIT License
0 stars 0 forks source link

Create a GAN for producing negative edges #9

Closed Kasper98-png closed 1 year ago

Kasper98-png commented 1 year ago

In a Generative Adversarial Network (GAN) architecture, a generator is trained to produce samples that are similar to the already existing samples. A discriminator is trained to distinguish between real samples and generated samples. Both of the models are commonly neural networks. Generative modeling is an unsupervised learning problem, but in a GAN it is designed as a supervised learning problem. The two models use each other to improve. In each training iteration the generator produces a batch of negative samples and the discriminator takes the generated samples and real samples from the domain. The discriminator then classifies each sample as real or fake (generated) and gets updated based on its performance. The input to the generator is random noise which acts as a seed for the generator. (https://machinelearningmastery.com/what-are-generative-adversarial-networks-gans/)

In the context of negative edge sampling, the generator is trained on positive edges to learn patterns and become good at generating negative samples that look like positive samples from the real domain data. This way the embedding network uses the pattern based negative edges instead of random negative edges.

rtni20 commented 1 year ago

https://arxiv.org/abs/1809.11017 Incorporating GAN for Negative Sampling in Knowledge Representation Learning Abstract Knowledge representation learning aims at modeling knowledge graph by encoding entities and relations into a low dimensional space. Most of the traditional works for knowledge embedding need negative sampling to minimize a margin-based ranking loss. However, those works construct negative samples through a random mode, by which the samples are often too trivial to fit the model efficiently. In this paper, we propose a novel knowledge representation learning framework based on Generative Adversarial Networks (GAN). In this GAN-based framework, we take advantage of a generator to obtain high-quality negative samples

rtni20 commented 1 year ago

A tutorial of implementing a Deep Convolutional Generative Adversarial Network with Py-Torch https://pytorch.org/tutorials/beginner/dcgan_faces_tutorial.html

Kasper98-png commented 1 year ago

https://colab.research.google.com/drive/1246XGJbtbqQ4pb86tGk64hZAF3_bV6hM?usp=sharing