SCIoT separates its edge server, client variants, and development tools into uv extras. Install only the profile needed by the target system.
- Python:
3.11 - TensorFlow:
2.15.0 - Configuration format: YAML
TensorFlow is selected automatically:
| Platform | Package |
|---|---|
| macOS Apple Silicon | tensorflow-macos==2.15.0 |
| macOS Intel | tensorflow==2.15.0 |
| Linux x86-64 | tensorflow==2.15.0 |
| Linux ARM | tensorflow==2.15.0 |
Windows is not currently part of the verified runtime matrix.
See docs/TENSORFLOW_KERAS_POLICY.md for the authoritative TensorFlow/Keras policy, model-loading compatibility shim, manual platform verification matrix, and troubleshooting guidance.
uv sync --no-devThe base installation contains only dependencies shared by the server and Python clients:
- NumPy
- Pillow
- PyYAML
It is useful for inspecting shared modules, but a runtime extra is required to run a server or client.
uv sync --extra server --no-dev
uv run python src/server/edge/run_edge.pyThe server profile includes FastAPI, Uvicorn, MQTT, WebSocket, NTP, and TensorFlow dependencies. It does not install camera, dashboard, plotting, or research packages.
uv sync --extra client-static --no-dev
uv run python src/client/python/http_client.pyThis profile includes TensorFlow, HTTP, and profiling dependencies. It does not install server or camera packages.
uv sync --extra client-laptop --no-dev
uv run python src/client/python/http_clientCAMlaptop.pyFor the benchmark variant:
uv run python src/client/python/benchmark.pyThe profile adds OpenCV to the standard client dependencies. Camera availability and permissions are managed by the host operating system.
Picamera2 is installed through Raspberry Pi OS because its Linux system dependencies cannot be represented safely in a cross-platform Python lockfile.
On Raspberry Pi OS:
sudo apt update
sudo apt install python3-picamera2
uv venv --python 3.11 --system-site-packages
uv sync --extra client-raspberry-pi --no-dev
uv run python src/client/python/http_clientCAMpi.pyAlternative method
python3 -m venv --system-site-packages .venv
python3 -m ensurepip
pip3 install pillow pyyaml psutil picamera2 tensorflowFor the Raspberry Pi benchmark variant, configure benchmark.py to use http_clientCAMpiBench.py, then run:
uv run python src/client/python/benchmark.pyThe Raspberry Pi profile was lockfile-validated, but camera hardware must be verified on a Raspberry Pi.
uv sync --extra analysis --no-devThis profile contains Pandas, Matplotlib, Seaborn, Plotly, Streamlit, SciPy, and profiling/analysis tools.
Examples:
uv run python plot_results.py
uv run streamlit run src/server/web/webpage.pyAnalysis can be combined with a runtime:
uv sync --extra server --extra analysis --no-devuv sync --extra research --no-devThe research profile currently contains FiftyOne and its larger dependency tree. It is intentionally excluded from every runtime profile.
For server-oriented tests:
uv sync --extra server --extra test
uv run pytestFor the complete local development environment:
uv sync \
--extra server \
--extra client-laptop \
--extra analysis \
--extra test \
--extra devuv sync performs an exact synchronization. Packages belonging only to a previously selected extra are removed when switching profiles.
For example:
uv sync --extra server --no-dev
uv sync --extra client-static --no-devAfter the second command, the environment represents the static client rather than a combined server/client installation. Specify multiple --extra arguments when both are needed.
Use named project environments to keep the installations fully isolated:
# Prepare the environments once.
UV_PROJECT_ENVIRONMENT=.venv-server \
uv sync --extra server --no-dev
UV_PROJECT_ENVIRONMENT=.venv-client \
uv sync --extra client-static --no-devThen run them in separate terminals:
# Terminal 1
UV_PROJECT_ENVIRONMENT=.venv-server \
uv run python src/server/edge/run_edge.py
# Terminal 2
UV_PROJECT_ENVIRONMENT=.venv-client \
uv run python src/client/python/http_client.pyAlternatively, install a combined environment:
uv sync --extra server --extra client-static --no-devThe following checks were performed in separate clean environments:
- Server: TensorFlow, FastAPI, Uvicorn, MQTT, and WebSockets installed; OpenCV, Picamera2, Streamlit, and FiftyOne absent.
- Static client: TensorFlow, Requests, urllib3, and psutil installed; server, camera, dashboard, and research packages absent.
- Laptop client: static client dependencies plus OpenCV; server, Raspberry Pi camera, dashboard, and research packages absent.
- Raspberry Pi client: dependency resolution verified; Picamera2 hardware validation remains platform-specific.