Giter Site home page Giter Site logo

Comments (3)

Philipp-Sc avatar Philipp-Sc commented on September 6, 2024

Random Forest vs Neural Net:

Pros:

  • captures (most important) independent variables

Cons:

  • can not capture complex relationships between variables

from llm-fraud-detection.

Philipp-Sc avatar Philipp-Sc commented on September 6, 2024
Test results on train=test dataset.
Random Forest Regressor:
Threshold >= 0.4: True Positive = 8876, False Positive = 128, Precision = 0.986, Recall = 0.985, F-Score = 0.985

Neural Net:
Threshold >= 0.4: True Positive = 8900, False Positive = 30, Precision = 0.997, Recall = 0.988, F-Score = 0.992

Neural Net performs best when all features are used.

train/test dataset with split ratio of 80%/20%.
Train:
Threshold >= 0.5: True Positive = 7076, False Positive = 27, Precision = 0.996, Recall = 0.987, F-Score = 0.992

Test:
Threshold >= 0.5: True Positive = 1669, False Positive = 69, Precision = 0.960, Recall = 0.946, F-Score = 0.953

Might be over fitted to some extend, still the test F-Score lacks behind the Random Forest.

Selected features with importance >= 0.01:

Random Forest Regressor:
Threshold >= 0.4: True Positive = 1700, False Positive = 94, Precision = 0.948, Recall = 0.939, F-Score = 0.943
Neural Net:
Threshold >= 0.4: True Positive = 1593, False Positive = 97, Precision = 0.943, Recall = 0.899, F-Score = 0.920

Neural Net performs worse that Random Forests when the features are reduces via importance score.
If the importance is computed from the NN, it performs worse (F-Score = 0.79).

from llm-fraud-detection.

Philipp-Sc avatar Philipp-Sc commented on September 6, 2024

add Neural Net prediction as feature to final Random Forest.

As long as the number of topics is limited by the available compute (CPU only) it makes no sense to replace the Random Forest.

from llm-fraud-detection.

Related Issues (16)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.