ObjectTorch is a Python-based image classification tool that allows you to train and test your own custom models. It uses TensorFlow and Keras to build and train a convolutional neural network (CNN) for image classification. The project provides a simple command-line interface to manage your models.
- Train Custom Models: Train your own image classification models on your datasets.
- Test Models: Use your trained models to make predictions on new images.
- Text-to-Speech: Get audible feedback for predictions.
- Simple CLI: Easy-to-use command-line interface for managing models.
To get a local copy up and running follow these simple steps.
- Python 3.12
- pip
- Clone the repo
git clone https://github.com/your_username/your_repository.git
- Install PIP packages
pip install -r requirements.txt
Run the Leading.py
script to start the application:
python Leading.py
You will be presented with the following options:
- Test The Model (1): Load a pre-trained model and classify an image.
- Create The Model (2): Train a new model on a dataset.
- Delete The Model (3): Remove a saved model.
- Clear The Screen (*): Clear the console.
- Exit (0): Close the application.
- Choose option
2
to create a new model. - Select the directory containing your dataset. The dataset should be organized into subdirectories, where each subdirectory represents a class.
- Enter the number of epochs you want to train the model for.
- Once training is complete, you can save the model to a specified location.
- Choose option
1
to test a model. - Select the directory where your saved model (
.keras
file) and class mapping (.json
file) are located. - Select an image you want to classify.
- The model will predict the class of the image and display the result.
.
├── Leading.py
├── README.md
├── requirements.txt
└── Test_Data
├── class1
│ ├── 1.jpg
│ └── ...
└── class2
├── 1.jpg
└── ...