This repository supersedes the earlier Plant-Imager repository, aligning with the updated design and requirements of the Plant Imager v3 robot.
This repository contains four Python subpackages:
commons: The common utilities and interfaces used by other packages.controller: A Qt-based Python package intended for the main Raspberry Pi 4 or 5. This package acts as the central controller and provides a touchscreen interface.picamera: A Python package designed for the Raspberry Pi Zero W with a camera. It manages video streaming and image capture.webui: A Dash-based Python package also for the main Raspberry Pi 4 or 5. It offers a client interface for plant scanning.
To quickly set up the development environment for Plant-Imager3, use the following comprehensive setup script:
# Create a new Conda environment with Python 3.11 and IPython
conda create -n plant-imager3 'python==3.11' ipython -y
# Activate the newly created environment
conda activate plant-imager3
# Install project subpackages in editable mode
pip install -e src/commons/.
pip install -e src/controller/.
pip install -e src/webui/.
# Install plantdb server dependencies
pip install plantdb.serverTo run the QtApp, you must install the required Mesa packages. On Ubuntu, you can do this by executing the following commands:
sudo apt update
sudo apt install libegl1-mesa libgl1-mesa-dri libgl1-mesa-glx mesa-utilsTo create a new conda environment, named plant-imager3, with Python3.11 & IPython:
conda create -n plant-imager3 'python==3.11' ipython
conda activate plant-imager3To install the plantimager.commons subpackage, run the following command from the root directory of the repository:
pip install -e src/commons/.To install the plantimager.controller subpackage, run the following command from the root directory of the repository:
pip install -e src/controller/.After installation, you can start the PlantImagerApp with:
plant-imager-controller-appTo install the plantimager.picamera subpackage, run the following command from the root directory of the repository:
pip install -e src/picamera/.For instructions on how to install the plantimager.webui subpackage, have a look here.
For instructions on how to start the WebUI application, have a look here.
This application requires a running FSDB REST API to interact with, notably to get available dataset names and to receive data from the Plant Imager.
For development purposes, providing that you have the plantdb.commons and plantdb.server libraries installed, you may start one with:
fsdb_rest_api --test