GithubHelp home page GithubHelp logo

hn410 / exploring-weight-balancing-on-long-tailed-recognition-problem Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 68 KB

ICLR 2024 - Official implementation for "Exploring Weight Balancing on Long-Tailed Recognition Problem"

Home Page: https://arxiv.org/abs/2305.16573

License: Other

Python 100.00%
deep-learning long-tailed-recognition pytorch

exploring-weight-balancing-on-long-tailed-recognition-problem's Introduction

Exploring-Weight-Balancing-on-Long-Tailed-Recognition-Problem (ICLR2024)

[ArXiV] [OpenReview]

Code Description

This repository comprises code for LTR. Primarily, one can conduct training (or logit adjustment) and assess the model by executing first.py and second.py at the top level.

  • first.py: Code for the initial stage of training.
  • second.py: Code for the subsequent stage of training or logit adjustment.

This repository is based on the paper and repository of Alshammari et al. Please refer to them as well.

How to Execute

  1. Setup environment. Refer to Requirement.
  2. Prepare datasets. If you want to experiment with CIFAR, this program automatically download them to the datasets directory. If you want to use ImageNet or other datasets, place them in the datasets folder beforehand. The location can be modified in utils/conf.py.
  3. Execute. Run the program by executing first.py or second.py. You can reproduce experiments detailed in our paper by specifying the JSON file path in the jsons directory. For instance:
python first.py --seeds 0 --json_path "./jsons/Cifar100/first.json"
python second.py --seeds 0 --json_path "./jsons/Cifar100/second.json"
  1. Check the results by examining the standard output and the exp folder.

Requirement

  1. Install pip, Python, and PyTorch. Our environment specifications are depicted below. Other versions might function, albeit reproducibility of results cannot be guaranteed.
    • Python version: Python 3.6.8
    • PyTorch verion: 1.10.1+cu113
  2. Install the libraries via pip using the following command.
pip install -U scikit-image pandas seaborn ipykernel scikit-learn tensorboard

Citation

If you find our model or methodology beneficial, kindly cite our work:

@inproceedings{
  hasegawa2024exploring,
  title={Exploring Weight Balancing on Long-Tailed Recognition Problem},
  author={Naoya Hasegawa and Issei Sato},
  booktitle={The Twelfth International Conference on Learning Representations},
  year={2024},
  url={https://openreview.net/forum?id=JsnR0YO4Fq}
}

exploring-weight-balancing-on-long-tailed-recognition-problem's People

Contributors

hn410 avatar

Stargazers

Jeff Carpenter avatar Keisuke Kamahori avatar

Watchers

Kostas Georgiou avatar  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.