Problem: Fraud detection Task : classifying transactions as either fraud/ Non-fraud using GAN

  • $\begingroup$ I am working on "Fraud detection using Deep learning". The dataset for that is "Credit card frauds" from kaggle. I have to explore GAN for this problem. But unlike the algorithm of GAN, I don't want to generate data from the generator. I don't want both generator and discriminator to play a minimax game in order to achieve their objective function. I have balanced the dataset using SMOTE. Now, what if I only implement discriminator for it? Would it be a GAN ? $\endgroup$ – Neha soni Dec 24 '18 at 18:26

Generative networks was the first popular class of topologies that had compound feedback, corrective signaling at more than one layer. In popular network designs such as MLPs (multilayer perceptrons), CNNs (convolutional neural networks), and LSTM (long short term memory) networks, the backpropagation is a single layer mechanism. The mechanism distributes corrective a signal creating a closed loop that ideally converges to an optimal network behavior.

The speed, accuracy, and reliability of convergence of networks in an AI system depend on a number of engineering choices at a lower level of design and development.

  • Selection of algorithm variants and extensions
  • Selection of data set
  • Drawing of the training samples
  • Data normalization
  • Initialization
  • Assignment of learning rate or learning rate policy
  • Other hyper-parameters

Generative networks are designed to achieve a higher level balance between two networks, each of which have their own backpropagation, and thus have a compound feedback topology.

Considering the original GAN approach in the context of fraud detection, a discriminative network $D$, in a way, detects fraudulence originating from the generative network $G$, and, in a way, $G$ learns authenticity from the corrective signal provided by $D$, even if the authenticity learned is superficial. However, in the case of credit card fraud detection from a numerical set of data, the fraudulence is not internal to the system to be designed as in the case of GAN. Without both the $G$ and $D$ networks, the design is not a generative network.

Since the comment stated, "I have to explore GAN for this problem," the key question is this.

If this system is to benefit from a GAN, what would the GAN generate that could contribute to the solution?

If the answer is nothing, then a GAN is not the correct approach. A discriminative network without a generative network is not a GAN. If this question is from an assignment to train a network using a static and already existing data set, a MLP may suffice, depending on the expectations of the teaching staff. If that is the case, the goal will be to analyze the data set using statistical tools to determine if it is already normalized well enough to lead to excellent convergence accuracy, speed, and reliability. If normalization is indicated, find ways to present the data to the input layer of the MLP in such a way that each input is relevant and has a well distributed range of values across the data type.

Ensure there is no data loss in this process, and remove redundancy where it can easily be removed. By redundancy removal is meant, if one of the dimensions of data have only four possible values of between 10 and 1,000 bytes, encode the four possible values in two bits because to do so removes unnecessary burden from the training.

Similarly, the output layer must be chosen to produce an encoded set of possible output values and the decoding must be written to produce usable output. In this case, it appears that the labels are, Fraudulent and Authentic. Which means that the last layer would be a single binary threshold cell.

For this simple MLP approach and for many of the approaches mentioned next, there are examples available in Python, Java, C++ and other languages from which implementation can be initiated. If the design must stand up to a more realistic fraud detection scenario, either for credit cards, junk mail, banking, log-in, or communications those experienced with fraud detection know that the above approach is entirely insufficient except as a starting point for learning. In such a case, these considerations further complicate the design of the solution.

  • Fraudulence and authenticity is not necessarily sufficient information for investigators. The likelihood of fraudulence and the reason why fraudulence is suspected is also pertinent for end users of production output, so that security holes can be blocked and investigation may be directed toward prosecution or some other set of remedies.
  • Fraudulence is usually a security breach phenomena that involves continuous improvement in the attacks until the attackers are located and their work is interrupted by arrest. What initially works as fraud detection may not work a week, a day, an hour, or a minute later.
  • Fraud detection, if it to be useful in a real financial context, must be part of a fraud prevention system, and training on a static data set may be meaningless in that larger usage environment.

In AI systems that work in real production environments, it may be worth investigating using an LSTM network in combination with a reinforcement learner. Such may be over a beginner's level of design and implementation experience, but using either an LSTM network or a basic Q-learning approach instead of both of them together may be a reasonable starting point for dedicated students. If the answer to the question about what a GAN could generate that would be of use must be yes, the following ideas may be helpful.

  • A generative network could generate transaction data with a distribution that resembles authentic transactions, and such has been successful in the past.
  • A generative network could generate transaction data with a distribution that resembles attacks on an account by a fraudulent user. That has been done too.
  • A generative network could theoretically generate hacker agents, although this may not have yet been done.
  • A generative network could be used to generate patterns of authentic transactions based on some authenticity measure other than the data set mentioned, and the trained discriminative network could then be employed in some way in a fraud detection system in production, although it is unclear what advantage would be gained.

The reason a GAN was suggested would need to be clarified before this answer could provide a more exact direction for AI system topology and project approach.

| improve this answer | |

Yes, although the traditional technique is to use Anomaly Detection for this sort of problem. The reason for that is that the space of possible frauds is very much larger than the space of legitimate transactions and so it is difficult to model the former. The usual idea is to thoroughly explore the smaller space of legitimate transactions and flag as fraudulent anything outside of that space. Using the GAN method could be interesting as it might identify novel fraud techniques, and those are always useful to know.

| improve this answer | |
  • $\begingroup$ What if I don't want to implement generator and only want to implement discriminator for the above mentioned problem in GAN as I have balanced dataset through SMOTE. Is it possible and Can it be done? $\endgroup$ – Neha soni Dec 22 '18 at 9:12
  • 1
    $\begingroup$ Yes. The discriminator in a GAN is just a binary classifier so you can use it to check for fraud / not fraud. $\endgroup$ – DrMcCleod Dec 22 '18 at 14:30
  • $\begingroup$ Which neural network to be used as a discriminator for best possible results? $\endgroup$ – Neha soni Dec 24 '18 at 5:05
  • $\begingroup$ What sort of data are you working with? $\endgroup$ – DrMcCleod Dec 24 '18 at 9:08
  • $\begingroup$ Numerical data. "Credit card Fraud detection " dataset from kaggle. $\endgroup$ – Neha soni Dec 24 '18 at 18:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.