Skip to content

This project includes multiple models, loss functions, optimizers and image augmentations for image classification task

License

Notifications You must be signed in to change notification settings

ngocphucck/Sleeping-posture-classification

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

IR-pose-classification

Requirements

Installation

  • Clone this repository:
git clone https://github.com/ngocphucck/IR-pose-classification
cd IR-pose-classification
  • Install dependencies: Please type the command pip install -r requirements.txt.

Implementations

  • Firstly, you have to prepare your annotations. I recommend that you organize your labelling file into 2 files: train.json and val.json with the form image_path: label.

  • After that, you can define some parameters in your method. There are 2 options for you to do that:

    • Change parameters in defaults.py.
    • Another way is to be more flexible. You'll create YAML configuration files; typically, you'll make one for each experiment. But, when actually implementing, you need to merge this .yaml file with defaults.py. The following code makes this action:
    cfg = get_cfg('path_to_file')
    cfg.merge_from_file("experiment.yaml")
    cfg.freeze()
  • Train a model:

cd tools
python train.py

Components

Backbones Loss functions Optimizers Augmentations
  • Cross Entropy
  • Adam
  • RandAug

Future works

  • Multiple backbones
  • Data augmentations
  • Multiple loss functions
  • Experiment managment
  • Edge devices deployment
  • UI demo/Docker resource
  • Distributed computing

Releases

No releases published

Packages

No packages published

Languages