Skip to content

SurgeonTalus/ImageDetection-Renamer-Tensorflow-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 

Repository files navigation

ImageDetectionRenamer LocalAI

Select a folder with images. Tensorflow will create a new name of the images based on their content.

Description

This script uses TensorFlow to perform object detection on a set of image files in a specified folder. It identifies the object in each image, renames the image file to include the predicted object name, and adds a version number if necessary to avoid overwriting existing files.

Dependencies

  • tkinter: for the GUI used to select the folder.
  • tensorflow: for the image processing and object detection.

To install these dependencies on IntelMac, you can use the following command:

pip install tkinter tensorflow

M1 To install these dependencies, you can use the following command:

Get Tensorflow working on M1:

Miniconda3 macOS Apple M1 64-bit pkg from https://docs.conda.io/en/latest/miniconda.html

Open terminal and run these lines separate:

conda install -c apple tensorflow-deps
pip install tensorflow-macos
pip install tensorflow-metal

conda install notebook -y

pip install numpy --upgrade pip install pandas --upgrade pip install matplotlib --upgrade pip install scikit-learn --upgrade pip install scipy --upgrade pip install plotly --upgrade

How to Use

  1. Install the dependencies listed above.
  2. Put your images in a folder.
  3. Run the script. Open terminal, type cd "path to folder", hit enter. Then tpye "python3 RenameImageAI Tensorflow Github.py" .
  4. A GUI window will appear allowing you to select the folder containing the image files.
  5. The script will process each image file in the selected folder, renaming them with the predicted object name and a version number if necessary.
  6. The original image files will be replaced with the renamed files.

Note: The script expects the image files to be in JPEG or PNG format, and will only process files with those extensions. If the script encounters any errors during processing, it will print an error message but continue processing the remaining images.

Screenshot Screenshot

https://github.com/SurgeonTalus/ImageDetectionRenamer-LocalAI-IntelOnly-/blob/main/Choose%20Files.png

https://github.com/SurgeonTalus/ImageDetectionRenamer-LocalAI-IntelOnly-/blob/main/Renamed%20Files.png

About

Select a folder with images. Tensorflow will create a new name of the images based on their content.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages