.. Copyright (c) AIME GmbH and affiliates. Find more info at https://www.aime.info/api This software may be used and distributed according to the terms of the AIME COMMUNITY LICENSE AGREEMENT Setup AIME API Server ~~~~~~~~~~~~~~~~~~~~~ Setup the environment ^^^^^^^^^^^^^^^^^^^^^ We recommend creating a virtual environment for local development. Create and activate a virtual environment, like 'venv' with: .. highlight:: shell .. code-block:: shell python3 -m venv venv source ./venv/bin/activate Download or clone the api server: .. highlight:: shell .. code-block:: shell git clone https://github.com/aime-team/aime-api-server.git Then install required pip packages: .. highlight:: shell .. code-block:: shell pip install -r requirements.txt Optional: install ffmpeg (required for image and audio conversion) Ubuntu/Debian: .. highlight:: shell .. code-block:: shell sudo apt install ffmpeg Start the API server ^^^^^^^^^^^^^^^^^^^^^ To start the API server run: .. highlight:: shell .. code-block:: shell python3 run_api_server.py [-H HOST] [-p PORT] [-c EP_CONFIG] [--dev] Optional command line parameters: * ``[-as, --api_server]`` *: Address of the AIME API Server. Default:* ``http://0.0.0.0:7777`` * ``[-H, --host]`` *: Host address of AIME ML API Server. Default:* ``0.0.0.0`` * ``[-p, --port]`` *: Port of AIME ML API Server. Default:* ``7777`` * ``[-s, --server_config]`` *: Destination of server config file. Default:* ``model_api_server.cfg`` * ``[-c, --ep_config]`` *: Destination of endpoint config file or folder. Default:* ``./endpoints`` * ``[--dev]`` *: Run the server in debug/development mode* * ``[-wp, --worker_processes]`` *: Number of api server worker processes. Default:* ``1`` * ``[--hide_logging]`` *: Hide logging in console* * ``[--no_colour]`` *: No level colours in logger*