Train mask image classifier model in Google Colab (with GPU)
Install Raspberry Pi OS 64-bit on RPi 4B
Optional - before installing, add an empty file called ssh
(without extension) to the root of the drive, to enable SSH.
Overclock Raspberry Pi to 1750MHz, overvolt to 3V
sudo nano /boot/config.txt
arm_freq=1750
over_voltage=3
Optional - enable these lines on /boot/config.txt
for VNC:
hdmi_force_hotplug=1
disable_overscan=1
gpu_mem=128
Post install
After install, in terminal:
sudo apt update
sudo apt full-upgrade
Istall OpenCV v4.5.0 or higher (for arch64
)
Install TensorFlow 2 v2.4.0 or higher (for arch64
)
Ater install, in terminal:
sudo apt install protobuf
pip install pycocotools
pip install tf_slim
pip install tensorflow_hub
install protos for TensorFlow 2 Object Detection API
In terminal:
chmod +x install-requirements.sh
./install-requirements.sh
Clone repo
In terminal:
git clone --recurse-submodules https://github.com/lgariv/CollegeProject.git
Download TFLite model from Google Colab and place in the same folder
Run
In terminal:
python Object_detection_webcam_tflite.py