Skip to content

rahulphenomenon/fastai-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 

Repository files navigation

Image classification on Terminal using fast.ai

This tool lets you build an image classifier with a single terminal command by using resnet50 as a feature extractor.

Installation

This tool requires fast.ai and Python3 to be installed. Instructions to install fast.ai can be found here
Clone the repo and navigate to the folder on Terminal.

Data

Data must be arranged into 3 folders, train test and valid, in the form:
/data
    /train
        /class1
        /class2
        /class3
    /valid
        /class1
        /class2
        /class3
    /test

This can be done by installing the split-folders library

Parameters

  • Path: Compulsory parameter that specifies path to the folder containing training data.
  • batchsize: Sets the batchsize(defaults of 4)
  • epochs: Sets the number of epochs the model will train(defaults to 10)

Usage

Run the main.py script


$ python3 main.py pathtodata 

Optionally you can specify a custom batchsize and the number of epochs to train the model. After the model is done training it will be saved as model.pkl.

Coming soon

  • Transfer learning on other base models.
  • Finetuning base model
  • Visualizations

About

Transfer learning on terminal using fast.ai

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages