Skip to content

Using serve‐data.py to host the image data locally

Will O'Brien edited this page Feb 16, 2024 · 9 revisions

Navigate to the directory of image files you plan on hosting, as well as knowing the desired port to allow access to the images.

Copy serve-data.py into the directory of image files. Then, run the following command:

python3 serve-data.py <port number>

Which will begin the hosting server.

Use systemd to make sure the process is always running and always restarts after errors.


Currently, serve-data.py is being run from a root data directory on port 3030 so that all the images we use can be accessed from localhost:3030. The systemd service running this process is named label-studio-data.service.