How to Build from Source#
This guide provides step-by-step instructions for building the Video Accuracy Evaluation service from source.
Both the backend and UI images pin pip to 26.2 in system Python and in the
Poetry-created application virtual environment. Rebuild the images and recreate
the application containers to apply this pin to an existing deployment.
If you want to build the microservices image locally, you can optionally refer to the steps in the Building the Backend Image and Building the UI Image sections. These sections provide detailed instructions on how to build the Docker images for both the backend and UI components of the Video Accuracy Evaluation service separately.
If you want to build the images via docker compose, please refer to the section Build the Images via Docker Compose.
Once all the images are built, you can proceed to start the service using the docker compose command as described in the Get Started page.
Clone the Repository#
Clone the Edge AI Libraries repository and change to its root directory:
git clone --branch main https://github.com/open-edge-platform/edge-ai-libraries.git
cd edge-ai-libraries/tools/video-summary-accuracy-analyzer
Run the commands in this guide from the repository root unless otherwise noted.
Configure the environment variables#
The compose.yaml file names the images as ${REGISTRY:-intel/}video-accuracy-eval:${TAG:-latest} and ${REGISTRY:-intel/}video-accuracy-eval-ui:${TAG:-latest}. Export REGISTRY and TAG so that the images you build, pull, and run share the same coordinates:
export REGISTRY="intel/"
export TAG=latest
The scripts/setup_env.sh script also sets these defaults when they are not already defined.
Building the Backend Image#
To build the Docker image for the evaluation service, follow these steps:
Build the docker image using command:
docker build -t "${REGISTRY:-intel/}video-accuracy-eval:${TAG:-latest}" -f docker/Dockerfile .
Verify that the Docker image has been built successfully:
docker images | grep video-accuracy-eval
You should see an entry for
video-accuracy-evalwith thelatesttag.
Building the UI image#
To build the Docker image for the video-accuracy-eval-ui service, follow these steps:
Build the Docker image using the provided
Dockerfile:docker build -t "${REGISTRY:-intel/}video-accuracy-eval-ui:${TAG:-latest}" -f ui/docker/Dockerfile .
Verify that the Docker image has been built successfully:
docker images | grep video-accuracy-eval-ui
Build the Images via Docker Compose#
This guide explains how to build the images using the compose.yaml file via the docker compose command.
Set Up Environment Variables:
export HUGGINGFACEHUB_API_TOKEN=<your-huggingface-token> source scripts/setup_env.sh
Build the Docker images defined in the
compose.yamlfile:docker compose -f docker/compose.yaml build
Verify that the Docker images have been built successfully:
docker images | grep video-accuracy-eval
You should see entries for both
video-accuracy-evalandvideo-accuracy-eval-ui.
Running the Application Container#
After building the images for the Video Accuracy Evaluation application, you can run the application container using docker compose by following these steps:
Set Up Environment Variables:
export HUGGINGFACEHUB_API_TOKEN=<your-huggingface-token> source scripts/setup_env.sh
Start the Docker containers with the previously built images:
docker compose -f docker/compose.yaml up
Access the application:
Open your web browser and navigate to “http://< host-ip >:8101” to view the application dashboard.
Verification#
Ensure the application is running by checking the Docker container status:
docker psAccess the application dashboard and verify that it is functioning as expected.
Troubleshooting#
If you encounter any issues during the build or run process, check the Docker logs for errors:
docker logs -f <container-id>