### Install google-drive-ocamlfuse Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/advanced/mounting_cloud_storages.md Commands to add the PPA and install the google-drive-ocamlfuse package on Ubuntu. ```bash sudo add-apt-repository ppa:alessandro-strada/ppa sudo apt-get update sudo apt-get install google-drive-ocamlfuse ``` -------------------------------- ### Setup Python Environment for Manifest Tool Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/dataset_management/dataset_manifest.md Sets up a Python virtual environment and installs required packages for the dataset manifest creation tool using pip. ```bash python3 -m venv .env . .env/bin/activate pip install -U pip pip install -r utils/dataset_manifest/requirements.in ``` -------------------------------- ### Install Git on Ubuntu Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/basics/installation.md Install Git using the apt package manager. ```shell sudo apt-get --no-install-recommends install -y git ``` -------------------------------- ### Install CVAT packages Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/sdk/developer-guide.md Install the SDK and CLI packages. Use the editable flag for development purposes. ```bash pip install ./cvat-sdk ./cvat-cli ``` ```bash pip install -e ./cvat-sdk -e ./cvat-cli ``` -------------------------------- ### Install System Dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/running-tests.md Install required system-level utilities for testing on Linux. ```bash sudo apt-get update sudo apt-get install -y poppler-utils unrar ``` -------------------------------- ### Install CVAT SDK Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/sdk/_index.md Commands to install the base SDK and optional extras for specific functionality. ```bash pip install cvat-sdk ``` ```bash pip install "cvat-sdk[masks]" ``` ```bash pip install "cvat-sdk[pytorch]" ``` -------------------------------- ### Install npm dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/running-tests.md Prepares the test environment by installing required Node.js packages. ```bash cd tests yarn --immutable ``` -------------------------------- ### Install CVAT and Dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Clone the CVAT repository, set up a virtual environment, and install development dependencies. ```bash git clone https://github.com/cvat-ai/cvat cd cvat && mkdir keys logs python3 -m venv .env . .env/bin/activate pip install -U pip wheel setuptools pip install --no-binary lxml,xmlsec -r cvat/requirements/development.txt -r dev/requirements.txt ``` -------------------------------- ### Start Minikube with Registry Addons Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/advanced/k8s_deployment_with_helm.md Starts a Minikube instance with the registry and registry-aliases addons enabled. This is a prerequisite for certain local development or testing scenarios. ```sh minikube start --addons registry,registry-aliases ``` -------------------------------- ### Install CVAT SDK Source: https://github.com/cvat-ai/cvat/blob/develop/cvat-sdk/README.md Standard installation command for the CVAT Python SDK. ```bash pip install cvat-sdk ``` -------------------------------- ### Start Services on Arch Linux Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Commands to manually start the required redis and docker services. ```bash sudo systemctl start redis.service sudo systemctl start docker.service ``` -------------------------------- ### Get CLI Help Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md Use the --help option to get information on available common options, resources, actions, and action-specific options. ```bash cvat-cli --help # get help on available common options and resources cvat-cli --help # get help on actions for the given resource cvat-cli --help # get help on action-specific options ``` -------------------------------- ### Install generator dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/sdk/developer-guide.md Install the necessary requirements for the SDK generator. ```bash pip install -r cvat-sdk/gen/requirements.txt ``` -------------------------------- ### Install Detectron2 Locally Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/guides/serverless-tutorial.md Installs the Detectron2 library from a local clone. This command should be run from the root directory of the detectron2 project. ```bash python -m pip install -e . ``` -------------------------------- ### Install DICOM conversion dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/utils/dicom_converter/README.md Sets up a virtual environment and installs required Python packages. ```bash python3 -m venv .env . .env/bin/activate pip install -r requirements.txt ``` -------------------------------- ### Install dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/cvat-ui/README.md Use this command to install project dependencies in an immutable mode. ```bash yarn --immutable ``` -------------------------------- ### Install CVAT SDK with Masks Support Source: https://github.com/cvat-ai/cvat/blob/develop/cvat-sdk/README.md Installation command including the masks module extra. ```bash pip install "cvat-sdk[masks]" ``` -------------------------------- ### Install CVAT SDK with PyTorch Support Source: https://github.com/cvat-ai/cvat/blob/develop/cvat-sdk/README.md Installation command including the PyTorch adapter and auto-annotation extras. ```bash pip install "cvat-sdk[pytorch]" ``` -------------------------------- ### Install and configure blobfuse for Azure Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/advanced/mounting_cloud_storages.md Commands to install blobfuse and mount an Azure Blob Storage container on Ubuntu 20.04. ```bash wget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb sudo dpkg -i packages-microsoft-prod.deb sudo apt-get update ``` ```bash sudo apt-get install blobfuse fuse ``` ```bash export AZURE_STORAGE_ACCOUNT= export AZURE_STORAGE_ACCESS_KEY= MOUNT_POINT= ``` ```bash sudo mkdir -p /mnt/blobfusetmp ``` ```bash sudo chown /mnt/blobfusetmp ``` ```bash mkdir -p ${MOUNT_POINT} ``` ```bash blobfuse ${MOUNT_POINT} --container-name= --tmp-path=/mnt/blobfusetmp -o allow_other ``` -------------------------------- ### Install Docker and Docker Compose on Ubuntu Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/basics/installation.md Installs Docker and Docker Compose using official Ubuntu repositories. Ensure you have internet access and sudo privileges. ```shell sudo apt-get update sudo apt-get install ca-certificates curl sudo install -m 0755 -d /etc/apt/keyrings sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc sudo chmod a+r /etc/apt/keyrings/docker.asc echo \ "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \ $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}") stable" | \ sudo tee /etc/apt/sources.list.d/docker.list > /dev/null sudo apt-get update sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin ``` -------------------------------- ### Pascal VOC labelmap.txt Example Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/dataset_management/formats/format-voc.md An example of the labelmap.txt file used in Pascal VOC exports, defining labels and their associated properties. ```bash # labelmap.txt # label : color_rgb : 'body' parts : actions background::: aeroplane::: bicycle::: bird::: ``` -------------------------------- ### Initialize a CVAT Client Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/sdk/highlevel-api.md Shows how to instantiate a client using the make_client utility and how to configure it manually. ```python from cvat_sdk import make_client with make_client("https://app.cvat.ai", credentials=("user", "password")) as client: ... ``` ```python from cvat_sdk import Config, Client config = Config() ``` -------------------------------- ### TransT Deployment Status Output Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/guides/serverless-tutorial.md This is an example output of the `nuctl get functions` command, showing the status of the deployed TransT function. Verify that the STATE is 'ready'. ```text NAMESPACE | NAME | PROJECT | STATE | REPLICAS | NODE PORT nuclio | pth-dschoerk-transt | cvat | ready | 1/1 | 32771 ``` -------------------------------- ### Start development server Source: https://github.com/cvat-ai/cvat/blob/develop/cvat-ui/README.md Launches the UI development server with automatic rebuilds on file changes. ```bash yarn run start ``` -------------------------------- ### Start CVAT Community Default Stack Source: https://github.com/cvat-ai/cvat/blob/develop/README.md Clone the CVAT repository and launch the default Docker Compose stack to get CVAT running. Optionally, set the CVAT_HOST environment variable to your IP or domain. ```bash git clone https://github.com/cvat-ai/cvat cd cvat # Optional: set your IP or domain # export CVAT_HOST=your-ip-or-domain docker compose up -d ``` -------------------------------- ### Apply CVAT Migrations and Setup Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Run database migrations, collect static files, and create a superuser for CVAT. ```bash python manage.py migrate python manage.py migrateredis python manage.py collectstatic python manage.py syncperiodicjobs python manage.py createsuperuser ``` -------------------------------- ### Set up Detectron2 Virtual Environment and Install Dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/guides/serverless-tutorial.md Creates a virtual environment for Detectron2 and installs PyTorch (CPU version), torchvision, torchaudio, and opencv-python. Ensure you have the correct versions for your system. ```bash python3 -m venv .detectron2 . .detectron2/bin/activate pip install torch==1.8.1+cpu torchvision==0.9.1+cpu torchaudio==0.8.1 -f https://download.pytorch.org/whl/torch_stable.html pip install opencv-python ``` -------------------------------- ### Install AWS CLI Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/enterprise/kubernetes.md Installs the AWS CLI on a Linux system. Ensure you have unzip installed. ```bash curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" unzip awscliv2.zip sudo ./aws/install ``` -------------------------------- ### Install Node.js 20 on Ubuntu Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Installs Node.js version 20 and ensures Corepack is globally installed for package management. ```bash curl -fsSL https://deb.nodesource.com/setup_20.x | sudo bash - sudo apt-get install -y nodejs sudo npm -g install corepack # ensure corepack is installed ``` -------------------------------- ### Install Node.js and npm on Arch Linux Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Installs the LTS Gallium version of Node.js and npm, and ensures Corepack is globally installed. ```bash sudo pacman -S nodejs-lts-gallium npm sudo npm -g install corepack # ensure corepack is installed ``` -------------------------------- ### Build Static Site and SDK Documentation Source: https://github.com/cvat-ai/cvat/blob/develop/site/README.md Generate the static documentation site and SDK documentation using Python scripts. The output is placed in the 'public/' folder. ```bash python process_sdk_docs.py --input-dir ../cvat-sdk/docs/ --site-root . python build_docs.py ``` -------------------------------- ### Install Docsy Theme Dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/README.md Install Node.js dependencies for the Docsy theme using npm. Ensure Node.js v18.0 or later is installed. ```bash (cd site/ && npm ci) ``` -------------------------------- ### Install HDF5 and H5py (Mac) Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md If facing 'Failed building wheel for h5py' errors on Mac, install HDF5 via Homebrew and then install h5py. ```bash brew install hdf5 export HDF5_DIR="$(brew --prefix hdf5)" pip install --no-binary=h5py h5py ``` -------------------------------- ### Verify Git Installation Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/basics/installation.md Check if Git is installed on the system. ```shell git --version ``` -------------------------------- ### Clone and configure repository Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/pull-requests.md Initial setup for a local fork, including cloning the repository and adding the upstream remote. ```bash # Clone your fork of the repo into the current directory git clone https://github.com// # Navigate to the newly cloned directory cd # Assign the original repo to a remote called "upstream" git remote add upstream https://github.com// ``` -------------------------------- ### Serve Documentation Locally with Hugo Source: https://github.com/cvat-ai/cvat/blob/develop/site/README.md Start a local Hugo development server to preview the documentation site. Accessible at http://localhost:1313/docs/ by default. ```bash (cd site/ && hugo server) ``` -------------------------------- ### Pull and Install CVAT Helm Chart from Local Directory Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/advanced/k8s_deployment_with_helm.md Pulls the CVAT Helm chart, extracts it, and installs it from a local directory. Useful for inspecting or customizing the chart before installation. ```sh helm pull oci://registry-1.docker.io/cvat/cvat --version tar -xzf cvat-.tgz cd cvat ``` ```sh helm install \ . \ -n \ --create-namespace \ -f values.yaml \ -f values.override.yaml ``` -------------------------------- ### Install Emscripten SDK Source: https://github.com/cvat-ai/cvat/blob/develop/cvat-data/src/ts/3rdparty/README.md Commands to clone and initialize the Emscripten SDK environment. ```sh git clone https://github.com/emscripten-core/emsdk.git && cd emsdk ``` ```sh ./emsdk install latest-fastcomp ``` ```sh ./emsdk activate latest-fastcomp ``` -------------------------------- ### Create Project from Backup Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md Create a new project from a previously created project backup file. ```bash cvat-cli project create-from-backup project_backup.zip ``` -------------------------------- ### Set Up Python Virtual Environment for Production Build Source: https://github.com/cvat-ai/cvat/blob/develop/site/README.md Create and activate a Python virtual environment and install production dependencies using pip. ```bash cd site/ pip -m venv venv . venv/bin/activate pip install -r requirements.txt ``` -------------------------------- ### Create Project with Labels Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md Create a new project with a specified name and labels loaded from a JSON file. ```bash cvat-cli project create "new project" --labels labels.json ``` -------------------------------- ### Start CVAT Services Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/enterprise/docker.md Command to start the CVAT containers in detached mode. ```bash ./docker-compose.sh up -d ``` -------------------------------- ### Install Python Testing Dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/running-tests.md Install the necessary Python packages for running tests. ```bash pip install -r cvat/requirements/testing.txt ``` -------------------------------- ### List Projects Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md List all available projects. ```bash cvat-cli project ls ``` -------------------------------- ### Initialize the ApiClient Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/sdk/lowlevel-api.md Shows the standard way to instantiate an ApiClient using a Configuration object within a context manager. ```python from cvat_sdk.api_client import ApiClient, Configuration configuration = Configuration(host="http://localhost") with ApiClient(configuration) as api_client: ... ``` -------------------------------- ### Install Python test requirements Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/running-tests.md Installs dependencies for REST API, SDK, and CLI testing. ```bash pip install -e ./cvat-sdk -e ./cvat-cli -r ./tests/python/requirements.txt ``` -------------------------------- ### Build and Run CVAT Server Containers Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/running-tests.md Build the server image and start the OPA container required for testing. ```bash docker compose -f docker-compose.yml -f docker-compose.dev.yml build cvat_server ``` ```bash docker compose -f docker-compose.yml -f docker-compose.dev.yml up -d cvat_opa ``` -------------------------------- ### Install Dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/cvat-core/README.md Installs project dependencies using yarn with immutable mode for reproducible builds. ```bash yarn install --immutable ``` -------------------------------- ### Example SSH connection output Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/guides/serverless-tutorial.md Sample output showing a successful SSH connection to the host machine. ```text root@2d6cceec8f70:/opt/nuclio# ssh -R 5678:localhost:5678 nmanovic@192.168.50.188 The authenticity of host '192.168.50.188 (192.168.50.188)' can't be established. ECDSA key fingerprint is SHA256:0sD6IWi+FKAhtUXr2TroHqyjcnYRIGLLx/wkGaZeRuo. Are you sure you want to continue connecting (yes/no/[fingerprint])? yes Warning: Permanently added '192.168.50.188' (ECDSA) to the list of known hosts. nmanovic@192.168.50.188's password: Welcome to Ubuntu 20.04.2 LTS (GNU/Linux 5.8.0-53-generic x86_64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage 223 updates can be applied immediately. 132 of these updates are standard security updates. To see these additional updates run: apt list --upgradable Your Hardware Enablement Stack (HWE) is supported until April 2025. Last login: Fri Jun 25 16:39:04 2021 from 172.17.0.5 [setupvars.sh] OpenVINO environment initialized nmanovic@nmanovic-dl-node:~$ ``` -------------------------------- ### Python Auto-annotation Spec Example Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md Example of defining an auto-annotation detection function specification in Python. ```python import cvat_sdk.auto_annotation as cvataa spec = cvataa.DetectionFunctionSpec(...) def detect(context, image): ... ``` -------------------------------- ### Initialize CVAT Client Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/sdk/highlevel-api.md Basic client initialization pattern using a context manager. ```python with Client("https://app.cvat.ai", config=config) as client: client.login(("user", "password")) ... ``` -------------------------------- ### Authorize google-drive-ocamlfuse Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/advanced/mounting_cloud_storages.md Run this command to initiate the authorization process for Google Drive access and create default configuration files. ```bash google-drive-ocamlfuse ``` -------------------------------- ### Start and monitor CVAT Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/advanced/upgrade_guide.md Starts the CVAT containers and monitors the server logs during the database migration process. ```shell docker compose up -d ``` ```shell docker logs cvat_server -f ``` -------------------------------- ### Create Dataset Manifest for Video (Force) Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/dataset_management/dataset_manifest.md Use the --force flag to create a manifest even if the video does not contain enough keyframes. Specify an output directory with --output-dir. ```bash python utils/dataset_manifest/create.py --force --output-dir ~/Documents ~/Documents/video.mp4 ``` -------------------------------- ### Example JSON Labels File Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md An example of the JSON format required for specifying labels when creating a task. ```json [ { "name": "cat", "attributes": [] }, { "name": "dog", "attributes": [] } ] ``` -------------------------------- ### Install Ubuntu Dependencies Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Installs essential build tools, development libraries, and Python packages for Ubuntu 22.04/20.04. ```bash sudo apt-get update && sudo apt-get --no-install-recommends install -y build-essential curl git python3-dev python3-pip python3-venv python3-tk libldap2-dev libsasl2-dev libgeos-dev cargo ``` -------------------------------- ### Start CVAT Docker containers Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/running-tests.md Initializes the CVAT environment with necessary components for testing. ```shell docker compose \ -f docker-compose.yml \ -f docker-compose.dev.yml \ -f components/serverless/docker-compose.serverless.yml \ -f tests/docker-compose.minio.yml \ -f tests/docker-compose.file_share.yml up -d ``` -------------------------------- ### Start WSL Ubuntu Distribution Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Command to initiate the Ubuntu 18.04 environment within WSL. ```powershell wsl -d Ubuntu-18.04 ``` -------------------------------- ### Install Python 3.10 on Arch Linux Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/contributing/development-environment.md Installs Python 3.10 using pikaur, as CVAT specifically supports this version. ```bash pikaur -S python310 ``` -------------------------------- ### Build and Deploy CVAT with Serverless Support Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/guides/serverless-tutorial.md Use this command to start the CVAT containers with the serverless configuration enabled. ```bash docker compose -f docker-compose.yml -f docker-compose.dev.yml -f components/serverless/docker-compose.serverless.yml up -d --build ``` -------------------------------- ### Install Google Chrome on Ubuntu Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/basics/installation.md Installs Google Chrome Stable on Ubuntu systems. This browser is required for using CVAT. ```shell sudo curl https://dl-ssl.google.com/linux/linux_signing_key.pub -o /etc/apt/trusted.gpg.d/google.asc sudo sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list' sudo apt-get update sudo apt-get --no-install-recommends install -y google-chrome-stable ``` -------------------------------- ### Create Task with Bug Tracker and Image Quality Settings Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md Create a task with labels from a file, a link to a bug tracker, reduced image quality, and annotation from an XML file. ```bash cvat-cli --auth user-2 task create "task from dataset_1" --labels labels.json \ --bug_tracker https://bug-tracker.com/0001 --image_quality 75 --annotation_path annotation.xml \ --annotation_format "CVAT 1.1" local dataset_1/images/ ``` -------------------------------- ### Python Auto-annotation Factory Example Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/api_sdk/cli/_index.md Example of implementing an auto-annotation factory function in Python that returns an AA function object. ```python import cvat_sdk.auto_annotation as cvataa class _MyFunction: def __init__(...): ... spec = cvataa.DetectionFunctionSpec(...) def detect(context, image): ... def create(...) -> cvataa.DetectionFunction: return _MyFunction(...) ``` -------------------------------- ### Enable Minikube Registry Addons Source: https://github.com/cvat-ai/cvat/blob/develop/site/content/en/docs/administration/community/advanced/k8s_deployment_with_helm.md Enable the registry and registry-aliases addons for Minikube to run a local unsecured registry. ```shell minikube addons enable registry minikube addons enable registry-aliases ```