Giter Club home page Giter Club logo

anonymouscikm2023's Introduction

README

Old implententation code of Improve Deep Forest with Learnable Layerwise Augmentation Policy Schedules, please view our new code at https://github.com/dbsxfz/AugDF.

Introduction

This README provides an overview of the code used in our research paper. It explains the purpose of each file and describes the libraries and versions we utilized. The code implements two models, deep_forest.py and gcForestcs.py, which are modified versions capable of utilizing augmentation. The layer.py file contains the code for constructing each layer of the model, including the implementation of random erase functionality. The aug.py file contains our implemented search augmentation policy and its application in a complete model. The one_df class can be used to train a DF (Deep Forest) or its variants with the provided policy or without any policy. The aug_df class performs policy search and records the selected policies.

Libraries Used

The following libraries were used in our code:

Library Version
Python 3.9.16
scikit-learn 1.2.0
deep-forest 0.1.7
numpy 1.22.4

File Descriptions

  1. deep_forest.py - This file contains the modified version of the Deep Forest model that supports augmentation.
  2. gcForestcs.py - This file contains the modified version of the gcForest model that supports augmentation.
  3. layer.py - This file includes the code for constructing each layer of the model and implements the random erase functionality.
  4. aug.py - This file contains our implemented search augmentation policy and its integration into a complete model. It includes the one_df class, which can train a DF or its variants with the provided policy or without any policy, and the aug_df class, which performs policy search and records the selected policies.
  5. train_augDF.py - This file outlines the complete workflow for data preprocessing, model selection, and augmentation policy usage. To use the code with other datasets, you need to add dataset loading and preprocessing steps in train_augDF.py. Similarly, if you want to utilize other discovered augmentation policies, modifications should be made in train_augDF.py.
  6. run.sh - This shell script provides the complete training code for the arrhythmia dataset as an example. It trains the model five times, computes the mean and variance of the results, and redirects the output to the records folder for further examination.

Additional Notes

  • To make the code compatible with other databases, you need to add dataset loading and preprocessing steps in train_augDF.py.
  • If you want to utilize other discovered augmentation policies, modifications should be made in train_augDF.py.
  • After discovering augmentation policies, we found that abandoning the additional five-fold cross-validation can make better use of the data and achieve improved results. We have included the implementation code in deep_forest_schedule.py.

Please feel free to reach out if you have any further questions or need additional information.

Testing Note

In our experiments, we performed testing and result recording after training each layer to further save time. We assure you that there is no leakage of the test set during this process. However, if you have any concerns, you can refer to the test_arrhythmia.ipynb notebook provided, which includes code for retesting after training. Simply comment out all code related to the test set during the model training process.

Please feel free to reach out if you have any further questions or need additional information.

anonymouscikm2023's People

Contributors

dbsxfz avatar oswaldhongyu avatar

Watchers

 avatar

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.