Coder Social home page Coder Social logo

arbitrary_pu's Introduction

Learning from Positive & Unlabeled Data with Arbitrary Positive Shift

docs

Authors: Zayd Hammoudeh & Daniel Lowd
Link: NeurIPS'20

This repository contains the source code for reproducing the results in the paper "Learning from Positive and Unlabeled Data with Arbitrary Positive Shift" published at NeurIPS'20.

Running the Program

To run the program, enter the src directory and call:

python driver.py ConfigFile

where ConfigFile is one of the yaml configuration files in folder src/configs. If CUDA is installed on your system, the program enables CUDA execution automatically.

First Time Running the Program

The first time each configuration is run, the program automatically downloads any necessary dataset(s) and create any transfer learning representations automatically. Please note that this process can be time consuming --- in particular for 20 Newsgroups where creating the ELMo-based embeddings can take several hours.

These downloaded files are stored in a folder .data that is in the same directory as driver.py. If the program crashes while running a configuration for the first time, we recommend deleting or moving the .data to allow the program to redownload and reinitialize the source data.

Results

Results are printed to the console. The tool also creates a folder named res in the same directory as driver.py where it exports results in CSV format. It includes results for all learners using metrics:

  • Accuracy
  • AUROC
  • F1 Score

Requirements

Our implementation was tested in Python 3.6.5. Minimum testing was performed with 3.7.1 but requirements.txt may need to change depending on your local Python configuration. It uses the PyTorch neural network framework, version 1.3.1 and 1.4. For the full requirements, see requirements.txt in the src directory.

We recommend running our program in a virtual environment. Once your virtual environment is created and active, run the following in the src directory:

pip install --user --upgrade pip
pip install -r requirements.txt

License

MIT

Acknowledgements

This repository includes an implementation of PUc [1] that was provided by the tool's author Tomoya Sakai.

Citation

@inproceedings{Hammoudeh:2020,
    author = {Hammoudeh, Zayd and
              Lowd, Daniel},
    title = {Learning from Positive and Unlabeled Data with Arbitrary Positive Shift},
    year = {2020},
    booktitle = {Proceedings of the 34th Conference on Neural Information Processing Systems},
    series = {{NeurIPS}’20}
}

References

[1] Tomoya Sakai and Nobuyuki Shimizu. Covariate shift adaptation on learning from positive and unlabeled data. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 33, pp. 4838-4845, July 2019.

arbitrary_pu's People

Contributors

zaydh 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.