diff --git a/.github/workflows/test-install-dependencies.yml b/.github/workflows/test-install-dependencies.yml index fd8f6d84b..51546588f 100644 --- a/.github/workflows/test-install-dependencies.yml +++ b/.github/workflows/test-install-dependencies.yml @@ -4,11 +4,11 @@ workflow_dispatch: push: paths: - - 'docs/source/_static/install_dependencies.sh' + - 'docs/install_dependencies.sh' - 'examples/install_requirements.py' pull_request: paths: - - 'docs/source/_static/install_dependencies.sh' + - 'docs/install_dependencies.sh' - 'examples/install_requirements.py' jobs: @@ -30,7 +30,7 @@ - name: Install dependencies run: | ln -snf /usr/share/zoneinfo/UTC /etc/localtime && echo UTC > /etc/timezone # Otherwise tzdata installer prompts for user input - sed '/udevadm control --reload-rules && sudo udevadm trigger/d' docs/source/_static/install_dependencies.sh > tmp_script.sh # Doesn't work on docker + sed '/udevadm control --reload-rules && sudo udevadm trigger/d' docs/install_dependencies.sh > tmp_script.sh # Doesn't work on docker bash tmp_script.sh - name: Create a virtual environment if: endsWith(matrix.container_image, 'rolling') == true @@ -54,7 +54,7 @@ - uses: actions/checkout@v3 - name: Install dependencies run: | - sed '/udevadm control --reload-rules && sudo udevadm trigger/d' docs/source/_static/install_dependencies.sh > tmp_script.sh + sed '/udevadm control --reload-rules && sudo udevadm trigger/d' docs/install_dependencies.sh > tmp_script.sh bash tmp_script.sh - name: Create a virtual environment run: | diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt deleted file mode 100644 index 6bc5a25ac..000000000 --- a/docs/CMakeLists.txt +++ /dev/null @@ -1,65 +0,0 @@ -# This list specifies building of documentation using CMake - -# Specify path separator -set(SYS_PATH_SEPARATOR ";") -if(UNIX) - set(SYS_PATH_SEPARATOR ":") -endif() - -# Get doxygen build location form doxygen target -get_target_property(DOXYGEN_OUTPUT_DIR doxygen DOXYGEN_OUTPUT_DIR) -message(STATUS "Retrieved doxygen output dir from doxygen target: ${DOXYGEN_OUTPUT_DIR}") - -# Add input and output information for conf.py -set(SPHINX_SOURCE ${CMAKE_CURRENT_LIST_DIR}/source) -set(SPHINX_BUILD ${CMAKE_CURRENT_BINARY_DIR}/sphinx) - -# Add year information -string(TIMESTAMP build_year "%Y") -# Configure sphinx for the build -configure_file(conf.py.in "${CMAKE_CURRENT_BINARY_DIR}/conf.py" @ONLY) - -# Sphinx is required to build python documentation -# Find Python sphinx, by checking python -m sphinx -message(STATUS "Checking for sphinx") -execute_process(COMMAND ${PYTHON_EXECUTABLE} -m sphinx --version RESULT_VARIABLE error OUTPUT_QUIET ERROR_QUIET) -if(error) - set(message "Checking for sphinx - not found, target 'sphinx' not available") - if(NOT enforce) - message(STATUS ${message}) - else() - message(FATAL_ERROR ${message}) - endif() - # Exit - return() -else() - message(STATUS "Checking for sphinx - found, target 'sphinx' available") - - file(COPY ${SPHINX_SOURCE}/_static DESTINATION ${CMAKE_CURRENT_BINARY_DIR}) - # Ready up sphinx - needed values configured in conf.py - add_custom_target(sphinx ALL - ${CMAKE_COMMAND} -E env - # Environment variables - # PATH (dlls) - "PATH=${HUNTER_INSTALL_PREFIX}/bin${SYS_PATH_SEPARATOR}$ENV{PATH}" - # Python path (to find compiled module) - "PYTHONPATH=$${SYS_PATH_SEPARATOR}$ENV{PYTHONPATH}" - # ASAN in case of sanitizers - "${ASAN_ENVIRONMENT_VARS}" - ############ SPHINX - ${PYTHON_EXECUTABLE} -m sphinx -c ${CMAKE_CURRENT_BINARY_DIR} -W --keep-going -b html ${SPHINX_SOURCE} ${SPHINX_BUILD} - WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} - COMMENT "Generating documentation with Sphinx" - VERBATIM - COMMAND_EXPAND_LISTS - ) - - # Add dependency to library - add_dependencies(sphinx ${TARGET_NAME}) - - # Add dependency to doxygen (C++) if exists - if(TARGET doxygen) - add_dependencies(sphinx doxygen) - endif() - -endif() diff --git a/docs/_extensions/zephyr/warnings_filter.py b/docs/_extensions/zephyr/warnings_filter.py deleted file mode 100644 index 650a76134..000000000 --- a/docs/_extensions/zephyr/warnings_filter.py +++ /dev/null @@ -1,97 +0,0 @@ -""" -Warnings filter extension -######################### - -Copyright (c) 2021 Nordic Semiconductor ASA -SPDX-License-Identifier: Apache-2.0 - -Introduction -============ - -This Sphinx plugin can be used to filter out warnings that are known to be false -positives. The warnings are filtered out based on a set of regular expressions -given via an configuration file. The format of the configuration file is a -plain-text file where each line consists of a regular expression. Any lines -starting with ``#`` will be ignored. - -Configuration options -===================== - -- ``warnings_filter_config``: Configuration file. -- ``warnings_filter_silent``: Silent flag. If True, warning is hidden. If False - the warning is converted to an information message and displayed. -""" - -import logging -import re -from typing import Dict, Any, List - -from sphinx.application import Sphinx -from sphinx.util.logging import NAMESPACE - - -__version__ = "0.1.0" - - -class WarningsFilter(logging.Filter): - """Warnings filter. - - Args: - expressions: List of regular expressions. - silent: If true, warning is hidden, otherwise it is shown as INFO. - name: Filter name. - """ - def __init__(self, expressions: List[str], silent: bool, name: str = "") -> None: - super().__init__(name) - - self._expressions = expressions - self._silent = silent - - def filter(self, record: logging.LogRecord) -> bool: - if record.levelno != logging.WARNING: - return True - - for expression in self._expressions: - if re.match(expression, record.msg): - if self._silent: - return False - else: - record.levelno = logging.INFO - record.msg = f"Filtered warning: {record.msg}" - return True - - return True - - -def configure(app: Sphinx) -> None: - """Entry point. - - Args: - app: Sphinx application instance. - """ - - # load expressions from configuration file - with open(app.config.warnings_filter_config) as f: - expressions = list() - for line in f.readlines(): - if not line.startswith("#"): - expressions.append(line.rstrip()) - - # install warnings filter to all the Sphinx logger handlers - filter = WarningsFilter(expressions, app.config.warnings_filter_silent) - logger = logging.getLogger(NAMESPACE) - for handler in logger.handlers: - handler.filters.insert(0, filter) - - -def setup(app: Sphinx) -> Dict[str, Any]: - app.add_config_value("warnings_filter_config", "", "") - app.add_config_value("warnings_filter_silent", True, "") - - app.connect("builder-inited", configure) - - return { - "version": __version__, - "parallel_read_safe": True, - "parallel_write_safe": True, - } diff --git a/docs/ci.cmake b/docs/ci.cmake deleted file mode 100644 index 16708b844..000000000 --- a/docs/ci.cmake +++ /dev/null @@ -1,19 +0,0 @@ -# Builds library at 'build/' and prepares sphinx configuration at 'build/docs/conf.py' -set(project_root "${CMAKE_CURRENT_LIST_DIR}/..") - -# Get buildCommitHash for non release build -execute_process(COMMAND "git" "rev-parse" "HEAD" WORKING_DIRECTORY ${project_root} OUTPUT_VARIABLE buildCommitHash OUTPUT_STRIP_TRAILING_WHITESPACE) - -# Configure -execute_process(COMMAND ${CMAKE_COMMAND} - -D DEPTHAI_PYTHON_COMMIT_HASH:STRING=${buildCommitHash} - -D DEPTHAI_PYTHON_BUILD_DOCS:BOOL=YES - -D DEPTHAI_BUILD_DOCS:BOOL=YES - -D DEPTHAI_PYTHON_BUILD_DOCSTRINGS:BOOL=YES - -D DEPTHAI_PYTHON_FORCE_DOCSTRINGS:BOOL=YES - -S . -B build - WORKING_DIRECTORY ${project_root} COMMAND_ECHO STDOUT -) - -# Build -execute_process(COMMAND ${CMAKE_COMMAND} --build build --parallel 2 WORKING_DIRECTORY ${project_root} COMMAND_ECHO STDOUT) \ No newline at end of file diff --git a/docs/conf.py.in b/docs/conf.py.in deleted file mode 100644 index 1c057d961..000000000 --- a/docs/conf.py.in +++ /dev/null @@ -1,113 +0,0 @@ -# Configuration file for the Sphinx documentation builder. -# -# This file only contains a selection of the most common options. For a full -# list see the documentation: -# https://www.sphinx-doc.org/en/master/usage/configuration.html - -# -- Path setup -------------------------------------------------------------- - -# If extensions (or modules to document with autodoc) are in another directory, -# add these directories to sys.path here. If the directory is relative to the -# documentation root, use os.path.abspath to make it absolute, like shown here. -# - -import os -import sys -from pathlib import Path - -source_directory = Path('@SPHINX_SOURCE@') - -# Add path to built module -sys.path.insert(0, os.path.abspath('@CMAKE_BINARY_DIR@')) - -# Add _extensions -sys.path.insert(0, os.path.abspath(source_directory / ".." / "_extensions")) - -# -- Project information ----------------------------------------------------- - -project = "DepthAI API Docs" -html_show_copyright=False -author = "Luxonis" -version = u"@DEPTHAI_PYTHON_VERSION@" -release = version -pypi_release = "2.0.0.1" - - -# -- General configuration --------------------------------------------------- - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom -# ones. -extensions = [ - "sphinx_tabs.tabs", - "sphinx-prompt", 'sphinx_substitution_extensions', # Substitute certain variables inside code blocks - "breathe", # Generate sphinx documentation from doxygen - "sphinx.ext.autodoc", # Generate documentation from python module - "sphinx.ext.napoleon", - "autodocsumm", - "sphinx.ext.viewcode", - "sphinx.ext.intersphinx", - "sphinx.ext.autosectionlabel", # https://github.com/sphinx-doc/sphinx/issues/7697 wait for this and implement - "sphinx_rtd_theme", - "zephyr.warnings_filter", - 'sphinx.ext.mathjax', -] - -# See https://github.com/sphinx-doc/sphinx/issues/7728 -suppress_warnings = ['autosectionlabel.*'] - -# # Debug docstrings -# def autodoc_process_docstring(app, what, name, obj, options, lines): -# print('process: ', what, name, obj, options, lines) -# def setup(app): -# app.connect("autodoc-process-docstring", autodoc_process_docstring) - -# substitutions -rst_prolog = '.. |release| replace:: ' + release - -# Breathe Configuration -# Project name depthai-core -> path to doxygen generated by - -# Check if we're running on Read the Docs' servers (set path to generate doxygen manually) -breathe_projects = {"depthai-core": "@DOXYGEN_OUTPUT_DIR@/xml"} -# Set depthai-core as default breathe project -breathe_default_project = "depthai-core" - -# Add any paths that contain templates here, relative to this directory. -templates_path = ['_templates'] - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This pattern also affects html_static_path and html_extra_path. -exclude_patterns = [] - -# -- Options for zephyr.warnings_filter ----------------------------------- -warnings_filter_config = str(source_directory / ".." / "known-warnings.txt") -warnings_filter_silent = False - -# -- Options for HTML output ------------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# -html_theme = 'sphinx_rtd_theme' - -html_theme_options = { - "collapse_navigation" : False -} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ['_static'] -html_favicon = '_static/images/favicon.png' -html_css_files = [ - 'css/index.css', - 'https://docs.luxonis.com/en/latest/_static/css/navbar.css', -] -html_js_files = [ - 'https://docs.luxonis.com/en/latest/_static/js/navbar.js', -] -html_title = 'DepthAI documentation | Luxonis' - -intersphinx_mapping = {'python': ('https://docs.python.org/3', None)} diff --git a/docs/docker-compose.yml b/docs/docker-compose.yml deleted file mode 100644 index dc27094a3..000000000 --- a/docs/docker-compose.yml +++ /dev/null @@ -1,10 +0,0 @@ -version: "3" -services: - docs: - build: - dockerfile: docs/docker/dev.dockerfile - context: .. - volumes: - - ./:/app/docs - ports: - - 8000:8000 diff --git a/docs/docker/dev.dockerfile b/docs/docker/dev.dockerfile deleted file mode 100644 index 1054de6d4..000000000 --- a/docs/docker/dev.dockerfile +++ /dev/null @@ -1,14 +0,0 @@ -FROM ubuntu:20.04 - -ARG DEBIAN_FRONTEND=noninteractive -RUN apt-get update && apt-get install -y libusb-1.0-0-dev clang python3-opencv python3-pip clang-11 doxygen graphviz cmake git -RUN python3 -m pip install -U pip numpy when-changed - -ENV CC clang-10 -ENV CXX clang++-10 -WORKDIR /app -ADD docs/requirements.txt docs/requirements.txt -ADD docs/requirements_mkdoc.txt docs/requirements_mkdoc.txt -RUN python3 -m pip install -r docs/requirements.txt -ADD . . -CMD docs/docker/docker_run.sh diff --git a/docs/docker/docker_run.sh b/docs/docker/docker_run.sh deleted file mode 100755 index 7e1dc0361..000000000 --- a/docs/docker/docker_run.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash - -set -e - -cmake -S . -B build -D DEPTHAI_BUILD_DOCS=ON -D DEPTHAI_PYTHON_BUILD_DOCS=ON - -./docs/docker/update_docs.sh - -when-changed -r docs/source -c "bash /app/docs/docker/update_docs.sh" & - -python3 -m http.server --bind 0.0.0.0 8000 --directory build/docs/sphinx diff --git a/docs/docker/update_docs.sh b/docs/docker/update_docs.sh deleted file mode 100755 index 87783a886..000000000 --- a/docs/docker/update_docs.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -set -e - -cmake --build build --target doxygen sphinx --parallel diff --git a/docs/source/_static/install_dependencies.sh b/docs/install_dependencies.sh similarity index 100% rename from docs/source/_static/install_dependencies.sh rename to docs/install_dependencies.sh diff --git a/docs/known-warnings.txt b/docs/known-warnings.txt deleted file mode 100644 index c787dcbba..000000000 --- a/docs/known-warnings.txt +++ /dev/null @@ -1,8 +0,0 @@ -# Each line should contain the regular expression of a known Sphinx warning -# that should be filtered out -.*Duplicate C\+\+ declaration.*\n.*'\.\. cpp:class::.*dai::ADatatype'.* -.*Duplicate C\+\+ declaration.*\n.*'\.\. cpp:class::.*dai::Buffer'.* -.*Duplicate C\+\+ declaration, also defined at components/nodes/.* -.*Duplicate C\+\+ declaration, also defined at components/messages/.* -.*Duplicate C\+\+ declaration, also defined at components/pipeline.* -.*Duplicate C\+\+ declaration, also defined at components/device.* \ No newline at end of file diff --git a/docs/readthedocs/requirements.txt b/docs/readthedocs/requirements.txt deleted file mode 100644 index 41dc790fd..000000000 --- a/docs/readthedocs/requirements.txt +++ /dev/null @@ -1,2 +0,0 @@ -cmake==3.17.3 --r ../requirements.txt diff --git a/docs/redirects.yml b/docs/redirects.yml deleted file mode 100644 index 8f0b4f3c1..000000000 --- a/docs/redirects.yml +++ /dev/null @@ -1,193 +0,0 @@ -# To update redirects on the page, please use -# -# ``` -# rtd-redirects luxonis-depthai-python ./redirects.yml --pro --username --password -# ``` -# -# Username and password are the credentials you use to access the RTD website -# -# **You need to have sufficient privileges on the RTD to change the redirects** - -redirects: - "/samples/autoexposure_roi/": "/samples/ColorCamera/autoexposure_roi/" - "/samples/bootloader_config/": "/samples/bootloader/bootloader_config/" - "/samples/bootloader_version/": "/samples/bootloader/bootloader_version/" - "/samples/calibration_flash/": "/samples/calibration/calibration_flash/" - "/samples/calibration_flash_v5/": "/samples/calibration/calibration_flash_v5/" - "/samples/calibration_load/": "/samples/calibration/calibration_load/" - "/samples/calibration_reader/": "/samples/calibration/calibration_reader/" - "/samples/corner_detector/": "/samples/FeatureTracker/corner_detector/" - "/samples/depth_crop_control/": "/samples/StereoDepth/depth_crop_control/" - "/samples/depth_preview/": "/samples/StereoDepth/depth_preview/" - "/samples/device_queue_event/": "/samples/host_side/device_queue_event/" - "/samples/edge_detector/": "/samples/EdgeDetector/edge_detector/" - "/samples/encoding_max_limit/": "/samples/VideoEncoder/encoding_max_limit/" - "/samples/feature_tracker/": "/samples/FeatureTracker/feature_tracker/" - "/samples/flash_bootloader/": "/samples/bootloader/flash_bootloader/" - "/samples/image_manip_rotate/": "/samples/ImageManip/image_manip_rotate/" - "/samples/image_manip_tiling/": "/samples/ImageManip/image_manip_tiling/" - "/samples/imu_gyroscope_accelerometer/": "/samples/IMU/imu_gyroscope_accelerometer/" - "/samples/imu_rotation_vector/": "/samples/IMU/imu_rotation_vector/" - "/samples/mono_camera_control/": "/samples/MonoCamera/mono_camera_control/" - "/samples/mono_depth_mobilenetssd/": "/samples/mixed/mono_depth_mobilenetssd/" - "/samples/mono_full_resolution_saver/": "/samples/MonoCamera/mono_full_resolution_saver/" - "/samples/mono_mobilenet/": "/samples/MobileNet/mono_mobilenet/" - "/samples/mono_preview/": "/samples/MonoCamera/mono_preview/" - "/samples/object_tracker/": "/samples/ObjectTracker/object_tracker/" - "/samples/object_tracker_video/": "/samples/ObjectTracker/object_tracker_video/" - "/samples/opencv_support/": "/samples/host_side/opencv_support/" - "/samples/queue_add_callback/": "/samples/host_side/queue_add_callback/" - "/samples/rgb_camera_control/": "/samples/ColorCamera/rgb_camera_control/" - "/samples/rgb_depth_aligned/": "/samples/StereoDepth/rgb_depth_aligned/" - "/samples/rgb_encoding/": "/samples/VideoEncoder/rgb_encoding/" - "/samples/rgb_encoding_mobilenet/": "/samples/mixed/rgb_encoding_mobilenet/" - "/samples/rgb_encoding_mono_mobilenet/": "/samples/mixed/rgb_encoding_mono_mobilenet/" - "/samples/rgb_encoding_mono_mobilenet_depth/": "/samples/mixed/rgb_encoding_mono_mobilenet_depth/" - "/samples/rgb_full_resolution_saver/": "/samples/VideoEncoder/rgb_full_resolution_saver/" - "/samples/rgb_mobilenet/": "/samples/MobileNet/rgb_mobilenet/" - "/samples/rgb_mobilenet_4k/": "/samples/MobileNet/rgb_mobilenet_4k/" - "/samples/rgb_mono_encoding/": "/samples/VideoEncoder/rgb_mono_encoding/" - "/samples/rgb_preview/": "/samples/ColorCamera/rgb_preview/" - "/samples/rgb_rotate_warp/": "/samples/ImageManip/rgb_rotate_warp/" - "/samples/rgb_video/": "/samples/ColorCamera/rgb_video/" - "/samples/script_camera_control/": "/samples/Script/script_camera_control/" - "/samples/spatial_location_calculator/": "/samples/SpatialDetection/spatial_location_calculator/" - "/samples/spatial_mobilenet/": "/samples/SpatialDetection/spatial_mobilenet/" - "/samples/spatial_mobilenet_mono/": "/samples/SpatialDetection/spatial_mobilenet_mono/" - "/samples/spatial_object_tracker/": "/samples/ObjectTracker/spatial_object_tracker/" - "/samples/spatial_tiny_yolo/": "/samples/SpatialDetection/spatial_tiny_yolo/" - "/samples/stereo_depth_from_host/": "/samples/StereoDepth/stereo_depth_from_host/" - "/samples/stereo_depth_video/": "/samples/StereoDepth/stereo_depth_video/" - "/samples/system_information/": "/samples/SystemLogger/system_information/" - "/samples/tiny_yolo_v3_device_side_decoding/": "/samples/Yolo/tiny_yolo/" - "/samples/tiny_yolo_v4_device_side_decoding/": "/samples/Yolo/tiny_yolo/" - "/samples/video_mobilenet/": "/samples/MobileNet/video_mobilenet/" - "/samples/30_stereo_depth_from_host/": "/samples/StereoDepth/stereo_depth_from_host/" - "/samples/29_3_object_tracker_video/": "/samples/ObjectTracker/object_tracker_video/" - "/samples/29_2_spatial_object_tracker/": "/samples/ObjectTracker/spatial_object_tracker/" - "/samples/29_1_object_tracker/": "/samples/ObjectTracker/object_tracker/" - "/samples/28_camera_video_example/": "/samples/ColorCamera/rgb_video/" - "/samples/27_spatial_location_calculator/": "/samples/SpatialDetection/spatial_location_calculator/" - "/samples/26_3_spatial_tiny_yolo/": "/samples/SpatialDetection/spatial_tiny_yolo/" - "/samples/26_2_spatial_mobilenet_mono/": "/samples/SpatialDetection/spatial_mobilenet_mono/" - "/samples/26_1_spatial_mobilenet/": "/samples/SpatialDetection/spatial_mobilenet/" - "/samples/25_system_information/": "/samples/SystemLogger/system_information/" - "/samples/24_opencv_support/": "/samples/host_side/opencv_support/" - "/samples/23_autoexposure_roi/": "/samples/ColorCamera/autoexposure_roi/" - "/samples/22_2_tiny_yolo_v4_decoding_on_device/": "/samples/Yolo/tiny_yolo/" - "/samples/22_1_tiny_yolo_v3_decoding_on_device/": "/samples/Yolo/tiny_yolo/" - "/samples/20_color_rotate_warp/": "/samples/ImageManip/rgb_rotate_warp/" - "/samples/19_mono_camera_control/": "/samples/MonoCamera/mono_camera_control/" - "/samples/18_rgb_encoding_mobilenet/": "/samples/mixed/rgb_encoding_mobilenet/" - "/samples/17_video_mobilenet/": "/samples/MobileNet/video_mobilenet/" - "/samples/16_device_queue_event/": "/samples/host_side/device_queue_event/" - "/samples/15_rgb_mobilenet_4k/": "/samples/MobileNet/rgb_mobilenet_4k/" - "/samples/14_3_depth_crop_control/": "/samples/StereoDepth/depth_crop_control/" - "/samples/14_2_mono_camera_control/": "/samples/MonoCamera/mono_camera_control/" - "/samples/14_1_color_camera_control/": "/samples/ColorCamera/rgb_camera_control/" - "/samples/13_encoding_max_limit/": "/samples/VideoEncoder/encoding_max_limit/" - "/samples/11_rgb_encoding_mono_mobilenet/": "/samples/mixed/rgb_encoding_mono_mobilenet/" - "/samples/12_rgb_encoding_mono_mobilenet_depth/": "/samples/mixed/rgb_encoding_mono_mobilenet_depth/" - "/samples/10_mono_depth_mobilenetssd/": "/samples/mixed/mono_depth_mobilenetssd/" - "/samples/09_mono_mobilenet/": "/samples/MobileNet/mono_mobilenet/" - "/samples/08_rgb_mobilenet/": "/samples/MobileNet/rgb_mobilenet/" - "/samples/07_mono_full_resolution_saver/": "/samples/MonoCamera/mono_full_resolution_saver/" - "/samples/06_rgb_full_resolution_saver/": "/samples/VideoEncoder/rgb_full_resolution_saver/" - "/samples/05_rgb_mono_encoding/": "/samples/VideoEncoder/rgb_mono_encoding/" - "/samples/04_rgb_encoding/": "/samples/VideoEncoder/rgb_encoding/" - "/samples/03_depth_preview/": "/samples/StereoDepth/depth_preview/" - "/samples/02_mono_preview/": "/samples/MonoCamera/mono_preview/" - "/samples/01_rgb_preview/": "/samples/ColorCamera/rgb_preview/" - "/samples/14_color_camera_control/": "/samples/ColorCamera/rgb_camera_control/" - "/samples/21_mobilenet_decoding_on_device/": "/samples/MobileNet/rgb_mobilenet/" - "/samples/autoexposure_roi": "/samples/ColorCamera/autoexposure_roi/" - "/samples/bootloader_config": "/samples/bootloader/bootloader_config/" - "/samples/bootloader_version": "/samples/bootloader/bootloader_version/" - "/samples/calibration_flash": "/samples/calibration/calibration_flash/" - "/samples/calibration_flash_v5": "/samples/calibration/calibration_flash_v5/" - "/samples/calibration_load": "/samples/calibration/calibration_load/" - "/samples/calibration_reader": "/samples/calibration/calibration_reader/" - "/samples/corner_detector": "/samples/FeatureTracker/corner_detector/" - "/samples/depth_crop_control": "/samples/StereoDepth/depth_crop_control" - "/samples/depth_preview": "/samples/StereoDepth/depth_preview/" - "/samples/device_queue_event": "/samples/host_side/device_queue_event/" - "/samples/edge_detector": "/samples/EdgeDetector/edge_detector/" - "/samples/encoding_max_limit": "/samples/VideoEncoder/encoding_max_limit/" - "/samples/feature_tracker": "/samples/FeatureTracker/feature_tracker/" - "/samples/flash_bootloader": "/samples/bootloader/flash_bootloader/" - "/samples/image_manip_rotate": "/samples/ImageManip/image_manip_rotate/" - "/samples/image_manip_tiling": "/samples/ImageManip/image_manip_tiling/" - "/samples/imu_gyroscope_accelerometer": "/samples/IMU/imu_gyroscope_accelerometer/" - "/samples/imu_rotation_vector": "/samples/IMU/imu_rotation_vector" - "/samples/mono_camera_control": "/samples/MonoCamera/mono_camera_control/" - "/samples/mono_depth_mobilenetssd": "/samples/mixed/mono_depth_mobilenetssd/" - "/samples/mono_full_resolution_saver": "/samples/MonoCamera/mono_full_resolution_saver/" - "/samples/mono_mobilenet": "/samples/MobileNet/mono_mobilenet/" - "/samples/mono_preview": "/samples/MonoCamera/mono_preview/" - "/samples/object_tracker": "//samples/ObjectTracker/object_tracker/" - "/samples/object_tracker_video": "/samples/ObjectTracker/object_tracker_video/" - "/samples/opencv_support": "/samples/host_side/opencv_support/" - "/samples/queue_add_callback": "/samples/host_side/queue_add_callback/" - "/samples/rgb_camera_control": "/samples/ColorCamera/rgb_camera_control/" - "/samples/rgb_depth_aligned": "/samples/StereoDepth/rgb_depth_aligned/" - "/samples/rgb_encoding": "/samples/VideoEncoder/rgb_encoding/" - "/samples/rgb_encoding_mobilenet": "/samples/mixed/rgb_encoding_mobilenet/" - "/samples/rgb_encoding_mono_mobilenet": "/samples/mixed/rgb_encoding_mono_mobilenet/" - "/samples/rgb_encoding_mono_mobilenet_depth": "/samples/mixed/rgb_encoding_mono_mobilenet_depth/" - "/samples/rgb_full_resolution_saver": "/samples/VideoEncoder/rgb_full_resolution_saver/" - "/samples/rgb_mobilenet": "/samples/MobileNet/rgb_mobilenet/" - "/samples/rgb_mobilenet_4k": "/samples/MobileNet/rgb_mobilenet_4k/" - "/samples/rgb_mono_encoding": "/samples/VideoEncoder/rgb_mono_encoding/" - "/samples/rgb_preview": "/samples/ColorCamera/rgb_preview/" - "/samples/rgb_rotate_warp": "/samples/ImageManip/rgb_rotate_warp/" - "/samples/rgb_video": "/samples/ColorCamera/rgb_video/" - "/samples/script_camera_control": "/samples/Script/script_camera_control/" - "/samples/spatial_location_calculator": "/samples/SpatialDetection/spatial_location_calculator/" - "/samples/spatial_mobilenet": "/samples/SpatialDetection/spatial_mobilenet/" - "/samples/spatial_mobilenet_mono": "/samples/SpatialDetection/spatial_mobilenet_mono/" - "/samples/spatial_object_tracker": "/samples/ObjectTracker/spatial_object_tracker/" - "/samples/spatial_tiny_yolo": "/samples/SpatialDetection/spatial_tiny_yolo/" - "/samples/stereo_depth_from_host": "/samples/StereoDepth/stereo_depth_from_host/" - "/samples/stereo_depth_video": "/samples/StereoDepth/stereo_depth_video/" - "/samples/system_information": "/samples/SystemLogger/system_information/" - "/samples/tiny_yolo_v3_device_side_decoding": "/samples/Yolo/tiny_yolo/" - "/samples/tiny_yolo_v4_device_side_decoding": "/samples/Yolo/tiny_yolo/" - "/samples/video_mobilenet": "/samples/MobileNet/video_mobilenet/" - "/samples/30_stereo_depth_from_host": "/samples/StereoDepth/stereo_depth_from_host/" - "/samples/29_3_object_tracker_video": "/samples/ObjectTracker/object_tracker_video/" - "/samples/29_2_spatial_object_tracker": "/samples/ObjectTracker/spatial_object_tracker/" - "/samples/29_1_object_tracker": "/samples/ObjectTracker/object_tracker/" - "/samples/28_camera_video_example": "/samples/ColorCamera/rgb_video/" - "/samples/27_spatial_location_calculator": "/samples/SpatialDetection/spatial_location_calculator/" - "/samples/26_3_spatial_tiny_yolo": "/samples/SpatialDetection/spatial_tiny_yolo/" - "/samples/26_2_spatial_mobilenet_mono": "/samples/SpatialDetection/spatial_mobilenet_mono/" - "/samples/26_1_spatial_mobilenet": "/samples/SpatialDetection/spatial_mobilenet/" - "/samples/25_system_information": "/samples/SystemLogger/system_information/" - "/samples/24_opencv_support": "/samples/host_side/opencv_support/" - "/samples/23_autoexposure_roi": "/samples/ColorCamera/autoexposure_roi/" - "/samples/22_2_tiny_yolo_v4_decoding_on_device": "/samples/Yolo/tiny_yolo/" - "/samples/22_1_tiny_yolo_v3_decoding_on_device": "/samples/Yolo/tiny_yolo/" - "/samples/20_color_rotate_warp": "/samples/ImageManip/rgb_rotate_warp/" - "/samples/19_mono_camera_control": "/samples/MonoCamera/mono_camera_control/" - "/samples/18_rgb_encoding_mobilenet": "/samples/mixed/rgb_encoding_mobilenet/" - "/samples/17_video_mobilenet": "/samples/MobileNet/video_mobilenet/" - "/samples/16_device_queue_event": "/samples/host_side/device_queue_event/" - "/samples/15_rgb_mobilenet_4k": "/samples/MobileNet/rgb_mobilenet_4k/" - "/samples/14_3_depth_crop_control": "/samples/StereoDepth/depth_crop_control" - "/samples/14_2_mono_camera_control": "/samples/MonoCamera/mono_camera_control/" - "/samples/14_1_color_camera_control": "/samples/ColorCamera/rgb_camera_control/" - "/samples/13_encoding_max_limit": "/samples/VideoEncoder/encoding_max_limit/" - "/samples/11_rgb_encoding_mono_mobilenet": "/samples/mixed/rgb_encoding_mono_mobilenet/" - "/samples/12_rgb_encoding_mono_mobilenet_depth": "/samples/mixed/rgb_encoding_mono_mobilenet_depth/" - "/samples/10_mono_depth_mobilenetssd": "/samples/mixed/mono_depth_mobilenetssd/" - "/samples/09_mono_mobilenet": "/samples/MobileNet/mono_mobilenet/" - "/samples/08_rgb_mobilenet": "/samples/MobileNet/rgb_mobilenet/" - "/samples/07_mono_full_resolution_saver": "/samples/MonoCamera/mono_full_resolution_saver/" - "/samples/06_rgb_full_resolution_saver": "/samples/VideoEncoder/rgb_full_resolution_saver/" - "/samples/05_rgb_mono_encoding": "/samples/VideoEncoder/rgb_mono_encoding/" - "/samples/04_rgb_encoding": "/samples/VideoEncoder/rgb_encoding/" - "/samples/03_depth_preview": "/samples/StereoDepth/depth_preview/" - "/samples/02_mono_preview": "/samples/MonoCamera/mono_preview/" - "/samples/01_rgb_preview": "/samples/ColorCamera/rgb_preview/" - "/samples/14_color_camera_control": "/samples/ColorCamera/rgb_camera_control/" - "/samples/21_mobilenet_decoding_on_device": "/samples/MobileNet/rgb_mobilenet/" \ No newline at end of file diff --git a/docs/requirements.txt b/docs/requirements.txt deleted file mode 100644 index 680df7b44..000000000 --- a/docs/requirements.txt +++ /dev/null @@ -1,12 +0,0 @@ -Sphinx==3.4.3 -sphinx-tabs==1.3.0 -sphinx-rtd-theme==0.5.2 -git+https://github.com/VanDavv/rtd-redirects.git@3e7333898acad533b37c9de426f1f2ef258d756b -breathe==4.26.0 -Sphinx-Substitution-Extensions==2020.9.30.0 -sphinx-autopackagesummary==1.3 -autodocsumm==0.2.2 -pathlib==1.0.1 -jinja2==3.0.3 -urllib3==1.26.15 # New urllib version breaks sphinx --r ./requirements_mkdoc.txt diff --git a/docs/source/_static/css/index.css b/docs/source/_static/css/index.css deleted file mode 100644 index 393d50c70..000000000 --- a/docs/source/_static/css/index.css +++ /dev/null @@ -1,107 +0,0 @@ -/* Additional styles or overrides */ - -h5 { - margin-bottom: 5%; -} - -.items-row { - display: flex; - margin-bottom: 5%; -} - -video { - max-width: 100%; -} - -.items-col { - width: 50% -} - -.item { - height: 100%; - padding: 0 15px; - display: flex; - flex-direction: column; - justify-content: space-between; -} - -.item .item-img-wrapper { - height: 200px; - margin-bottom: 10px; - text-align: center; -} - -.item .item-img-wrapper .item-img { - max-height: 100%; - max-width: 100%; -} - -.item .item-body { - flex-grow: 5; -} - -.item .item-cta { - width: 100%; -} - -.cta-row { - display: flex; - justify-content: space-between; - margin-bottom: 20px; -} - -.cta-row .cta-box { - width: 33%; - margin: 0 5px; - padding: 10px; - border: 1px solid rgba(0,0,0,.125); - border-radius: 10px; -} - -.cta-row .cta-box img { - width: 24px; - height: 24px; - margin-right: 10px; -} - -.cta-row .cta-box a { - display: flex; -} - -@media (max-width: 1000px) { - .cta-row { - flex-direction: column; - align-items: center; - } - .cta-row .cta-box { - margin: 5px 0; - width: 250px; - } -} - -@media (min-width: 600px) and (max-width: 1000px) { - .item .item-img-wrapper { - height: 150px; - } -} - -@media (min-width: 400px) and (max-width: 600px) { - .item .item-img-wrapper { - height: 100px; - } -} - -@media (max-width: 400px) { - .item .item-img-wrapper { - height: 50px; - } -} - -.wy-side-nav-search { - background-color: #004d80; -} - -.cta-row-short h5 { - margin-bottom: 0; -} - diff --git a/docs/source/_static/images/api_diagram.png b/docs/source/_static/images/api_diagram.png deleted file mode 100644 index 9f26a4d38..000000000 Binary files a/docs/source/_static/images/api_diagram.png and /dev/null differ diff --git a/docs/source/_static/images/components/Euclidian_distance_fig.png b/docs/source/_static/images/components/Euclidian_distance_fig.png deleted file mode 100644 index 67dca5303..000000000 Binary files a/docs/source/_static/images/components/Euclidian_distance_fig.png and /dev/null differ diff --git a/docs/source/_static/images/components/boot-depthai.jpeg b/docs/source/_static/images/components/boot-depthai.jpeg deleted file mode 100644 index cc786da14..000000000 Binary files a/docs/source/_static/images/components/boot-depthai.jpeg and /dev/null differ diff --git a/docs/source/_static/images/components/clock-syncing.png b/docs/source/_static/images/components/clock-syncing.png deleted file mode 100644 index ebff42fc6..000000000 Binary files a/docs/source/_static/images/components/clock-syncing.png and /dev/null differ diff --git a/docs/source/_static/images/components/depth_diagram.png b/docs/source/_static/images/components/depth_diagram.png deleted file mode 100644 index a45405433..000000000 Binary files a/docs/source/_static/images/components/depth_diagram.png and /dev/null differ diff --git a/docs/source/_static/images/components/device_timesync.jpg b/docs/source/_static/images/components/device_timesync.jpg deleted file mode 100644 index 115ef5ffb..000000000 Binary files a/docs/source/_static/images/components/device_timesync.jpg and /dev/null differ diff --git a/docs/source/_static/images/components/disp_to_depth.jpg b/docs/source/_static/images/components/disp_to_depth.jpg deleted file mode 100644 index c5bda25f5..000000000 Binary files a/docs/source/_static/images/components/disp_to_depth.jpg and /dev/null differ diff --git a/docs/source/_static/images/components/disparity_confidence.jpg b/docs/source/_static/images/components/disparity_confidence.jpg deleted file mode 100644 index 3d8d4b3b4..000000000 Binary files a/docs/source/_static/images/components/disparity_confidence.jpg and /dev/null differ diff --git a/docs/source/_static/images/components/disparity_explanation.jpeg b/docs/source/_static/images/components/disparity_explanation.jpeg deleted file mode 100644 index e5450fd20..000000000 Binary files a/docs/source/_static/images/components/disparity_explanation.jpeg and /dev/null differ diff --git a/docs/source/_static/images/components/disparity_shift.png b/docs/source/_static/images/components/disparity_shift.png deleted file mode 100644 index 83a3b5ee5..000000000 Binary files a/docs/source/_static/images/components/disparity_shift.png and /dev/null differ diff --git a/docs/source/_static/images/components/http_server.png b/docs/source/_static/images/components/http_server.png deleted file mode 100644 index ae868db63..000000000 Binary files a/docs/source/_static/images/components/http_server.png and /dev/null differ diff --git a/docs/source/_static/images/components/pointcloud_layering.jpg b/docs/source/_static/images/components/pointcloud_layering.jpg deleted file mode 100644 index 554816e8d..000000000 Binary files a/docs/source/_static/images/components/pointcloud_layering.jpg and /dev/null differ diff --git a/docs/source/_static/images/components/spatial-coordinates.png b/docs/source/_static/images/components/spatial-coordinates.png deleted file mode 100644 index 7aaaf3c6e..000000000 Binary files a/docs/source/_static/images/components/spatial-coordinates.png and /dev/null differ diff --git a/docs/source/_static/images/components/theoretical_error.jpg b/docs/source/_static/images/components/theoretical_error.jpg deleted file mode 100644 index 9b71d37a5..000000000 Binary files a/docs/source/_static/images/components/theoretical_error.jpg and /dev/null differ diff --git a/docs/source/_static/images/components/timestamp-difference.png b/docs/source/_static/images/components/timestamp-difference.png deleted file mode 100644 index 551b6450c..000000000 Binary files a/docs/source/_static/images/components/timestamp-difference.png and /dev/null differ diff --git a/docs/source/_static/images/components/tof-diagram.png b/docs/source/_static/images/components/tof-diagram.png deleted file mode 100644 index b885ae0df..000000000 Binary files a/docs/source/_static/images/components/tof-diagram.png and /dev/null differ diff --git a/docs/source/_static/images/components/tof-optical-correction.png b/docs/source/_static/images/components/tof-optical-correction.png deleted file mode 100644 index a405a8c2b..000000000 Binary files a/docs/source/_static/images/components/tof-optical-correction.png and /dev/null differ diff --git a/docs/source/_static/images/examples/collision_avoidance.gif b/docs/source/_static/images/examples/collision_avoidance.gif deleted file mode 100644 index 63447e2e7..000000000 Binary files a/docs/source/_static/images/examples/collision_avoidance.gif and /dev/null differ diff --git a/docs/source/_static/images/examples/depth_comparison.png b/docs/source/_static/images/examples/depth_comparison.png deleted file mode 100644 index 33ef4ba61..000000000 Binary files a/docs/source/_static/images/examples/depth_comparison.png and /dev/null differ diff --git a/docs/source/_static/images/examples/depth_video_synced.gif b/docs/source/_static/images/examples/depth_video_synced.gif deleted file mode 100644 index 1c37fd5e3..000000000 Binary files a/docs/source/_static/images/examples/depth_video_synced.gif and /dev/null differ diff --git a/docs/source/_static/images/examples/edge_detections.png b/docs/source/_static/images/examples/edge_detections.png deleted file mode 100644 index 587fec393..000000000 Binary files a/docs/source/_static/images/examples/edge_detections.png and /dev/null differ diff --git a/docs/source/_static/images/examples/feature_detector.png b/docs/source/_static/images/examples/feature_detector.png deleted file mode 100644 index 52c21e9c9..000000000 Binary files a/docs/source/_static/images/examples/feature_detector.png and /dev/null differ diff --git a/docs/source/_static/images/examples/feature_motion_estimation.gif b/docs/source/_static/images/examples/feature_motion_estimation.gif deleted file mode 100644 index 97819cce3..000000000 Binary files a/docs/source/_static/images/examples/feature_motion_estimation.gif and /dev/null differ diff --git a/docs/source/_static/images/examples/normalize_model.png b/docs/source/_static/images/examples/normalize_model.png deleted file mode 100644 index be861497a..000000000 Binary files a/docs/source/_static/images/examples/normalize_model.png and /dev/null differ diff --git a/docs/source/_static/images/examples/pointcloud_control.gif b/docs/source/_static/images/examples/pointcloud_control.gif deleted file mode 100644 index 0952f8291..000000000 Binary files a/docs/source/_static/images/examples/pointcloud_control.gif and /dev/null differ diff --git a/docs/source/_static/images/examples/scene.png b/docs/source/_static/images/examples/scene.png deleted file mode 100644 index 4b728db7c..000000000 Binary files a/docs/source/_static/images/examples/scene.png and /dev/null differ diff --git a/docs/source/_static/images/examples/visualize_pointcloud.png b/docs/source/_static/images/examples/visualize_pointcloud.png deleted file mode 100644 index 308780c78..000000000 Binary files a/docs/source/_static/images/examples/visualize_pointcloud.png and /dev/null differ diff --git a/docs/source/_static/images/favicon.png b/docs/source/_static/images/favicon.png deleted file mode 100644 index decd05d31..000000000 Binary files a/docs/source/_static/images/favicon.png and /dev/null differ diff --git a/docs/source/_static/images/references/centerCrop.png b/docs/source/_static/images/references/centerCrop.png deleted file mode 100644 index 5b34d4cbc..000000000 Binary files a/docs/source/_static/images/references/centerCrop.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/isp.jpg b/docs/source/_static/images/tutorials/isp.jpg deleted file mode 100644 index 3ae088d3b..000000000 Binary files a/docs/source/_static/images/tutorials/isp.jpg and /dev/null differ diff --git a/docs/source/_static/images/tutorials/multiple/setup.jpg b/docs/source/_static/images/tutorials/multiple/setup.jpg deleted file mode 100644 index 2d1b2b6eb..000000000 Binary files a/docs/source/_static/images/tutorials/multiple/setup.jpg and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/cmake.png b/docs/source/_static/images/tutorials/windows/cmake.png deleted file mode 100755 index f563d6062..000000000 Binary files a/docs/source/_static/images/tutorials/windows/cmake.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/execution_aliases.png b/docs/source/_static/images/tutorials/windows/execution_aliases.png deleted file mode 100755 index a0de178d8..000000000 Binary files a/docs/source/_static/images/tutorials/windows/execution_aliases.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/execution_search.png b/docs/source/_static/images/tutorials/windows/execution_search.png deleted file mode 100755 index 1492ef786..000000000 Binary files a/docs/source/_static/images/tutorials/windows/execution_search.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/git.png b/docs/source/_static/images/tutorials/windows/git.png deleted file mode 100755 index 6ce08c194..000000000 Binary files a/docs/source/_static/images/tutorials/windows/git.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/pip.png b/docs/source/_static/images/tutorials/windows/pip.png deleted file mode 100755 index 8b7490fe5..000000000 Binary files a/docs/source/_static/images/tutorials/windows/pip.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/pip_success.png b/docs/source/_static/images/tutorials/windows/pip_success.png deleted file mode 100755 index 3c4f5fc98..000000000 Binary files a/docs/source/_static/images/tutorials/windows/pip_success.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/powershell.png b/docs/source/_static/images/tutorials/windows/powershell.png deleted file mode 100755 index 314e3ba08..000000000 Binary files a/docs/source/_static/images/tutorials/windows/powershell.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/store.png b/docs/source/_static/images/tutorials/windows/store.png deleted file mode 100755 index 74a92382e..000000000 Binary files a/docs/source/_static/images/tutorials/windows/store.png and /dev/null differ diff --git a/docs/source/_static/images/tutorials/windows/vsstudio.png b/docs/source/_static/images/tutorials/windows/vsstudio.png deleted file mode 100755 index fc64f3f2a..000000000 Binary files a/docs/source/_static/images/tutorials/windows/vsstudio.png and /dev/null differ diff --git a/docs/source/_static/install_depthai.sh b/docs/source/_static/install_depthai.sh deleted file mode 100755 index d3270ff08..000000000 --- a/docs/source/_static/install_depthai.sh +++ /dev/null @@ -1,231 +0,0 @@ -#!/bin/bash - -APP_NAME="depthai" -WORKING_DIR_NAME="Luxonis" -WORKING_DIR="$HOME/$WORKING_DIR_NAME" -mkdir "$WORKING_DIR" -install_path="" -path_correct="false" - -trap 'RET=$? ; echo -e >&2 "\n\x1b[31mFailed installing depthai. Could be a bug in the installer or unsupported platform. Open a bug report over at https://github.com/luxonis/depthai - exited with status $RET at line $LINENO \x1b[0m\n" ; exit $RET' ERR - -while [ "$path_correct" = "false" ] -do - echo "" - echo 'ENTER absolute installation path for depthai or leave empty and default path: $HOME will be used.' - read -e install_path < /dev/tty - echo "" - - if [ "$install_path" = "" ]; then - echo "Using default installation path: $WORKING_DIR" - mkdir -p "$WORKING_DIR" - else - echo "Using given installation path: $install_path" - WORKING_DIR="$install_path" - fi - - if [ -d "$WORKING_DIR" ]; then - echo "Directory: $WORKING_DIR is OK" - path_correct="true" - else - echo "Directory: $WORKING_DIR is not valid. Try again!" - fi -done - -DEPTHAI_DIR="$WORKING_DIR/$APP_NAME" -VENV_DIR="$WORKING_DIR/venv" -ENTRYPOINT_DIR="$DEPTHAI_DIR/entrypoint" - -# Get Python version or find out that python 3.10 must be installed -python_executable=$(which python3) -python_chosen="false" -install_python="false" -python_version=$(python3 --version) -python_version_number="" -if [[ "$python_version" != 'Python'* ]]; then - python_version="" -fi -echo "" - -# check default python version, offer it to the user or get another one -while [ "$python_chosen" = "false" ] -do - if [[ "$python_version" == "" ]]; then - echo "No python version found." - echo "Input path for python binary, version 3.8 or higher, or leave empty and python 3.10 will be installed for you." - echo "Press ENTER key to continue" - read -e python_binary_path < /dev/tty - # python not found and user wants to install python 3.10 - if [ "$python_binary_path" = "" ]; then - install_python="true" - python_chosen="true" - fi - else - # E.g Python 3.10 -> nr_1=3, nr_2=10, for Python 3.7.5 -> nr_1=r, nr_2=7 - nr_1="${python_version:7:1}" - nr_2=$(echo "${python_version:9:2}" | tr -d -c 0-9) - echo "Python version: $python_version found." - if [ "$nr_1" -gt 2 ] && [ "$nr_2" -gt 7 ]; then # first two digits of python version greater then 3.7 -> python version 3.8 or greater is allowed. - echo "If you want to use it for installation, press ENTER key, otherwise input path to python binary." - echo "Press ENTER key to continue" - read -e python_binary_path < /dev/tty - # user wants to use already installed python whose version is high enough - if [ "$python_binary_path" = "" ]; then - python_chosen="true" - fi - else - echo "This python version is not supported by depthai. Enter path to python binary version et least 3.8, or leave empty and python 3.10 will be installed automatically." - echo "Press ENTER key to continue" - read -e python_binary_path < /dev/tty - # python version is too low and user wants to install python 3.10 - if [ "$python_binary_path" = "" ]; then - install_python="true" - python_chosen="true" - fi - fi - fi - # User entered some path that should lead to python binary, save python --version output and the rest is dealt in the while loop logic. - if [ "$python_binary_path" != "" ]; then - python_executable="$python_binary_path" - python_version=$($python_binary_path --version) - if [[ "$python_version" != 'Python'* ]]; then - python_version="" - fi - fi -done - - -write_in_file () { - # just make sure only strings are appended which are not in there yet - # first arg is text to write, second arg is the file path - if ! grep -Fxq "$1" "$2" - then - echo "$1" >> "$2" - fi -} - -COMMENT='# Entry point for Depthai demo app, enables to run in terminal' -BASHRC="$HOME/.bashrc" -ZSHRC="$HOME/.zshrc" -ADD_ENTRYPOINT_TO_PATH='export PATH=$PATH'":$ENTRYPOINT_DIR" - -# add to .bashrc only if it is not in there already -write_in_file "$COMMENT" "$BASHRC" -write_in_file "$ADD_ENTRYPOINT_TO_PATH" "$BASHRC" - -if [ -f "$ZSHRC" ]; then - write_in_file "$COMMENT" "$ZSHRC" - write_in_file "$ADD_ENTRYPOINT_TO_PATH" "$ZSHRC" -fi - -if [[ $(uname -s) == "Darwin" ]]; then - echo _____________________________ - echo "Calling macOS_installer.sh" - echo _____________________________ - echo "Running macOS installer." - - echo "Installing global dependencies." - bash -c "$(curl -fL https://docs.luxonis.com/install_dependencies.sh)" - - # clone depthai form git - if [ -d "$DEPTHAI_DIR" ]; then - echo "Demo app already downloaded. Checking out main and updating." - else - echo "Downloading demo app." - git clone https://github.com/luxonis/depthai.git "$DEPTHAI_DIR" - fi - cd "$DEPTHAI_DIR" - git fetch - git checkout main - git pull - - - if [ "$install_python" == "true" ]; then - echo "installing python 3.10" - brew install python@3.10 - python_executable=$(which python3.10) - fi - - - # create python virtual environment - echo "Creating python virtual environment in $VENV_DIR" - echo "$python_executable" - "$python_executable" -m venv "$VENV_DIR" - # activate environment - source "$VENV_DIR/bin/activate" - python -m pip install --upgrade pip - - # install launcher dependencies - pip install pyqt5 - pip install packaging - - # Inform macOS users about PATH changes - echo "DepthAI has been added to your PATH in .bashrc and .zshrc (if present)." - echo "If you prefer, you can manually add the following line to your .bash_profile for it to be recognized in login shells:" - echo "export PATH=\$PATH:$ENTRYPOINT_DIR" - -elif [[ $(uname -s) == "Linux" ]]; then - echo _____________________________ - echo "Calling linux_installer.sh" - echo _____________________________ - - echo "Updating sudo-apt." - sudo apt-get update - - echo "Installing global dependencies." - sudo wget -qO- https://docs.luxonis.com/install_dependencies.sh | bash - - echo -e '\nRunning Linux installer.' - - # clone depthai form git - if [ -d "$DEPTHAI_DIR" ]; then - echo "Demo app already downloaded. Checking out main and updating." - - else - echo "Downloading demo app." - git clone https://github.com/luxonis/depthai.git "$DEPTHAI_DIR" - fi - - cd "$DEPTHAI_DIR" - git fetch - git checkout main - git pull - - # install python 3.10 - if [ "$install_python" == "true" ]; then - echo "installing python 3.10" - - sudo yes "" | sudo add-apt-repository ppa:deadsnakes/ppa - sudo apt -y install python3.10 - sudo apt -y install python3.10-venv - python_executable=$(which python3.10) - fi - - echo "Creating python virtual environment in $VENV_DIR" - - machine=$(uname -m) - if [[ $machine != 'armv6l' && $machine != 'armv7l' && $machine != 'aarch64' && $machine != 'arm64' ]]; then - "$python_executable" -m venv "$VENV_DIR" - else - "$python_executable" -m venv "$VENV_DIR" --system-site-packages - fi - - source "$VENV_DIR/bin/activate" - python -m pip install --upgrade pip - - pip install packaging - - if [[ $machine != 'armv6l' && $machine != 'armv7l' && $machine != 'aarch64' && $machine != 'arm64' ]]; then - pip install pyqt5 - fi -else - echo "Error: Host $(uname -s) not supported." - exit 99 -fi - -echo -e '\n\n:::::::::::::::: INSTALATION COMPLETE ::::::::::::::::\n' -echo -e '\nTo run demo app write in terminal.' -echo "Press ENTER KEY to finish and run the demo app..." -read -n1 key < /dev/tty -echo "STARTING DEMO APP." -python "$DEPTHAI_DIR/launcher/launcher.py" -r "$DEPTHAI_DIR" diff --git a/docs/source/components/bootloader.rst b/docs/source/components/bootloader.rst deleted file mode 100644 index 68f4f199f..000000000 --- a/docs/source/components/bootloader.rst +++ /dev/null @@ -1,153 +0,0 @@ -.. _components_bootloader: - -Bootloader -========== - -DepthAI bootloader is a small program which handles the booting process, either by **booting the flashed application** (see :ref:`Standalone mode`), -or by **initializing the OAK PoE camera** so DepthAI API can connect to it. OAK PoE cameras already come with factory bootloader flashed at the factory. - -Bootloader is bundled inside with the ``depthai`` library, so to eg. flash the newest bootloader, you should use the newest ``depthai`` library. - -Device Manager -############## - -``device_manager.py`` is a Python script that interfaces with device :ref:`Bootloader` and bootloader configuration. -It can be found at `depthai-python/utilities `__. - -.. image:: https://github.com/luxonis/depthai-python/assets/18037362/1de0d86f-58bf-4979-b7d0-5ca7723db599 - -About Device ------------- - -Allows you to select the device you want to connect to, and you see metadata of connected device. - -* First we have to select the device we want to connect (boot) to, you can select that using: - - * **Dropdown** which contains found device MX Ids. Dropdown will only get updated when starting the app. - * **Specify IP** button if your OAK PoE camera isn't in the same LAN. - * **Search** feature - a new window will show that has a table with all available cameras (either via USB port or on LAN - OAK PoEs), their MxId, name, and status. Clicking on a table row will select that device and boot to it. - -Configuration settings ----------------------- - -After you select a device that has bootloader flashed, you can also configure bootloader configuration. - -- If the device has **NETWORK bootloader flashed**, you will be able to set its static/dynamic IP/mask/gateway, DNS, MAC, etc. -- If the device has **USB bootloader flashed**, you will be able to set its USB max speed and USB timeout. - -After setting some values, you have to click on the ``Flash configuration`` button. You can also ``Clear configuration``, or ``View configuration`` (its JSON). - -.. figure:: https://github.com/luxonis/depthai-python/assets/18037362/4bced0ab-92fa-4a73-986f-4a3ba8848940 - - When flashing static IP, make sure to also set the gateway/mask - -Applications settings ---------------------- - -Useful when dealing with :ref:`Standalone mode` applications. - -- **Flash application**: Select DepthAI Application Package (``.dap``) you want to flash the device. Below is a code snippet that showcases how to create the dap file. -- **Remove application**: Removes/clears the flashed application from the device -- **Open device streaming application**: Starts streaming frames from all connected cameras on the device. - -.. code-block:: python - - import depthai as dai - pipeline = dai.Pipeline() - # ... add nodes to pipeline - dai.DeviceBootloader.saveDepthaiApplicationPackage( - './file.dap', # Where to save the .dap file - pipeline, # My pipeline - compress=True, # Compress the FW and assets. In my case, it went from 24MB -> 9.5MB - applicationName='myAppName' # Optional, so you know which app is flashed afterwards - ) - -Danger Zone ------------ - -.. warning:: - - This section can potentially soft-brick your device, so be careful when using it. - -To prevent soft-bricking, OAK devices (since 2023) have factory bootloader and user bootloader. If user flashes a corrupted user bootloader, it will fallback to using factory bootloader. When updating bootloader, -Device Manager will try to flash the user bootloader first, if flashed (factory) bootloader supports it. If it's not possible, it will flash the factory bootloader. - -* **Update Bootloader** button will flash the newest bootloader to the device. You can select AUTO, USB or NETWORK bootloader. - - * AUTO will select the connection type of bootloader with which the camera is currently connected to. If you are connected via USB (doing factory reset) to an OAK PoE camera, you shouldn't select AUTO, as it will flash USB bootloader. - * USB bootloader will try to boot the application that is stored on flash memory. If it can't find flashed application, it will just behave as normal USB OAK - so it will wait until a host computer initializes the application. - * NETWORK bootloader is used by the OAK PoE cameras, and is flashed at the factory. It handles network initialization so the OAK PoE cameras can be booted through the LAN. -* **Flash Factory Bootloader**: If you want to flash the factory bootloader, you can use this button. It will flash the factory bootloader, even if the user bootloader is already flashed. -* **Factory reset** will erase the whole flash content and re-flash it with only the USB or NETWORK bootloader. Flashed application (pipeline, assets) and bootloader configurations will be lost. -* **Boot into USB recovery mode** will force eg. OAK PoE camera to be available through the USB connector, even if its boot pins are set to PoE booting. It is mostly used by our firmware developers. - -Factory and User bootloader -########################### - -There are two types of bootloaders: - -- **Factory bootloader**: bootloader that is flashed in the factory. We don't recommend re-flashing this bootloader, as it is not meant to be edited by end users. -- **User bootloader**: bootloader that can be flashed by the user. If booting is unsuccessful (eg. gets corrupted when flashing), it will fallback to factory bootloader. - -USB devices don't support user bootloader. If device has User bootloader, it will be used by default. If user bootloader is not flashed, it will fallback to Factory bootloader. - -Boot switches -############# - -- **Boot from flash** - DIP switch: 0x03 (switches 5,6 ON) - used by OAK PoE and USB cameras when bootloader is installed. -- **Recovery mode for USB** - DIP switch: 0x16 (switches 2,4,5 ON) - to boot directly into USB mode, so camera waits for the host to connect to it via USB. - -.. figure:: https://user-images.githubusercontent.com/18037362/154956812-c3fcc961-af46-4dfd-8080-e15c8c6b43f0.png - - OAK-D-PoE with switches 2,4,5 ON, for the purpose of connecting to the device via USB. - -On newer versions of OAK devices we have 0 ohm resistors (see image below) instead of a DIP switch, which means OAK will boot into flash by default. These new devices -have the bootloader flashed, which handles the booting process. There's also an additional button on the baseboard that switches boot to recovery mode when -pressed, which can be useful if the bootloader hasn't yet been flashed (eg. early access devices). You need to press this button when powering the device (when booting -happens). - -.. image:: https://user-images.githubusercontent.com/18037362/207295832-613fae0a-c0ae-411e-b03b-8a4736f1bfc7.png - -API -### - -**DeviceBootloader** is a class to communicate with the bootloader. It is used to flash created :ref:`Pipeline`, depthai application package -or update the bootloader itself. - -.. code-block: cpp - - std::tuple flash(std::function progressCb, Pipeline& pipeline); - - std::tuple flashDepthaiApplicationPackage(std::function progressCb, std::vector package); - - std::tuple flashBootloader(std::function progressCb, std::string path = ""); - -progressCb parameter takes a callback function, which will be called each time an progress update occurs (rate limited to 1 second). This is mainly -used to inform the user of the current flashing progress. - -.. _DAP: - -DepthAI Application Package (.dap) -################################## - -**DepthAI application package** is a binary file format which stores sections of data. The purpose of this format is to be able to extract -individual sections and do OTA updates without requiring to update all data. Example: Between update 1 and 2 of users application, -Depthai firmware, Asset storage (50MiB neural network) and asset structure remained the same, but some additional processing nodes were added -to the pipeline. Instead of transferring the whole package, only Pipeline description can be sent and updated. - -Depthai application package (**.dap**) consists of: - -- SBR (512B header which describes sections of data) -- Depthai device firmware (section "__firmware") -- Pipeline description (section "pipeline") -- Assets structure (section "assets") -- Asset storage (section "asset_storage") - -MAC address -########### - -All OAK PoE cameras have a unique MAC address which is used to identify the device on the network. It is calculated from the -MxID of the device, see `logic here `__. -The MAC address is stored in the DeviceBootloader configuration. - -.. include:: ../includes/footer-short.rst diff --git a/docs/source/components/device.rst b/docs/source/components/device.rst deleted file mode 100644 index 83ccab3e0..000000000 --- a/docs/source/components/device.rst +++ /dev/null @@ -1,278 +0,0 @@ -.. _components_device: - -Device -====== - -Device is an `OAK camera `__ or a RAE robot. On all of our devices there's a powerful Robotics Vision Core -(`RVC `__). The RVC is optimized for performing AI inference, CV operations, and -for processing sensory inputs (eg. stereo depth, video encoders, etc.). - -Device API -########## - -:code:`Device` object represents an OAK device. When starting the device, you have to upload a :ref:`Pipeline` to it, which will get executed on the VPU. -When you create the device in the code, firmware is uploaded together with the pipeline and other assets (such as NN blobs). - -.. code-block:: python - - pipeline = depthai.Pipeline() - - # Create nodes, configure them and link them together - - # Upload the pipeline to the device - with depthai.Device(pipeline) as device: - # Print MxID, USB speed, and available cameras on the device - print('MxId:',device.getDeviceInfo().getMxId()) - print('USB speed:',device.getUsbSpeed()) - print('Connected cameras:',device.getConnectedCameras()) - - # Input queue, to send message from the host to the device (you can receive the message on the device with XLinkIn) - input_q = device.getInputQueue("input_name", maxSize=4, blocking=False) - - # Output queue, to receive message on the host from the device (you can send the message on the device with XLinkOut) - output_q = device.getOutputQueue("output_name", maxSize=4, blocking=False) - - while True: - # Get a message that came from the queue - output_q.get() # Or output_q.tryGet() for non-blocking - - # Send a message to the device - cfg = depthai.ImageManipConfig() - input_q.send(cfg) - -Connect to specified device -########################### - -If you have multiple devices and only want to connect to a specific one, or if your OAK PoE camera is outside of your -subnet, you can specify the device (either with MxID, IP, or USB port name) you want to connect to. - -.. code-block:: python - - # Specify MXID, IP Address or USB path - device_info = depthai.DeviceInfo("14442C108144F1D000") # MXID - #device_info = depthai.DeviceInfo("192.168.1.44") # IP Address - #device_info = depthai.DeviceInfo("3.3.3") # USB port name - with depthai.Device(pipeline, device_info) as device: - # ... - -Host clock syncing -################## - -When depthai library connects to a device, it automatically syncs device's timestamp to host's timestamp. Timestamp syncing happens continuously at around 5 second intervals, -and can be configured via API (example script below). - -.. image:: /_static/images/components/device_timesync.jpg - -Device clocks are synced at below 500µs accuracy for PoE cameras, and below 200µs accuracy for USB cameras at 1σ (standard deviation) with host clock. - -.. image:: /_static/images/components/clock-syncing.png - -Above is a graph representing the accuracy of the device clock with respect to the host clock. We had 3 devices connected (OAK PoE cameras), all were hardware synchronized using `FSYNC Y-adapter `__. -Raspberry Pi (the host) had an interrupt pin connected to the FSYNC line, so at the start of each frame the interrupt happened and the host clock was recorded. Then we compared frame (synced) timestamps with -host timestamps and computed the standard deviation. For the histogram above we ran this test for approximately 3 hours. - -Below is a graph representing the difference between the device and host clock. The graph shows the difference between the device and host clock over time. The graph is a result of the same test as the previous one. - -.. image:: /_static/images/components/timestamp-difference.png - -.. code-block:: python - - # Configure host clock syncing example - - import depthai as dai - from datetime import timedelta - # Configure pipeline - with dai.Device(pipeline) as device: - # 1st value: Interval between timesync runs - # 2nd value: Number of timesync samples per run which are used to compute a better value - # 3rd value: If true partial timesync requests will be performed at random intervals, otherwise at fixed intervals - device.setTimesync(timedelta(seconds=5), 10, True) # (These are default values) - - -Multiple devices -################ - -If you want to use multiple devices on a host, check :ref:`Multiple DepthAI per Host`. - -Device queues -############# - -After initializing the device, you can create input/output queues that match :ref:`XLinkIn`/:ref:`XLinkOut` nodes in the pipeline. These queues will be located on the host computer (in RAM). - -.. code-block:: python - - pipeline = dai.Pipeline() - - xout = pipeline.createXLinkOut() - xout.setStreamName("output_name") - # ... - xin = pipeline.createXLinkIn() - xin.setStreamName("input_name") - # ... - with dai.Device(pipeline) as device: - - outputQueue = device.getOutputQueue("output_name", maxSize=5, blocking=False) - inputQueue = device.getInputQueue("input_name") - - outputQueue.get() # Read from the queue, blocks until message arrives - outputQueue.tryGet() # Read from the queue, returns None if there's no msg (doesn't block) - if outputQueue.has(): # Check if there are any messages in the queue - - -When you define an output queue, the device can push new messages to it at any time, and the host can read from it at any time. - - -Output queue - `maxSize` and `blocking` -####################################### - -When the host is reading very fast from the queue (inside `while True` loop), the queue, regardless of its size, will stay empty most of -the time. But as we add things on the host side (additional processing, analysis, etc), it may happen that the device will be pushing messages to -the queue faster than the host can read from it. And then the messages in the queue will start to increase - and both `maxSize` and `blocking` -flags determine the behavior of the queue in this case. Two common configurations are: - -.. code-block:: python - - with dai.Device(pipeline) as device: - # If you want only the latest message, and don't care about previous ones; - # When a new msg arrives to the host, it will overwrite the previous (oldest) one if it's still in the queue - q1 = device.getOutputQueue(name="name1", maxSize=1, blocking=False) - - - # If you care about every single message (eg. H264/5 encoded video; if you miss a frame, you will get artifacts); - # If the queue is full, the device will wait until the host reads a message from the queue - q2 = device.getOutputQueue(name="name2", maxSize=30, blocking=True) # Also default values (maxSize=30/blocking=True) - -We used `maxSize=30` just as an example, but it can be any `int16` number. Since device queues are on the host computer, memory (RAM) usually isn't that scarce, so `maxSize` wouldn't matter that much. -But if you are using a small SBC like RPI Zero (512MB RAM), and are streaming large frames (eg. 4K unencoded), you could quickly run out of memory if you set `maxSize` to a high -value (and don't read from the queue fast enough). - -Some additional information ---------------------------- - -- Queues are thread-safe - they can be accessed from any thread. -- Queues are created such that each queue is its own thread which takes care of receiving, serializing/deserializing, and sending the messages forward (same for input/output queues). -- The :code:`Device` object isn't fully thread-safe. Some RPC calls (eg. :code:`getLogLevel`, :code:`setLogLevel`, :code:`getDdrMemoryUsage`) will get thread-safe once the mutex is set in place (right now there could be races). - -Watchdog -######## - -The watchdog is a crucial component in the operation of POE (Power over Ethernet) devices with DepthAI. When DepthAI disconnects from a POE device, the watchdog mechanism is the first to respond, -initiating a reset of the camera. This reset is followed by a complete system reboot, which includes the loading of the DepthAI bootloader and the initialization of the entire networking stack. - -The watchdog process is necessary to make the camera available for reconnection and **typically takes about 10 seconds**, which means the fastest possible reconnection time is 10 seconds. - - -Customizing the Watchdog Timeout --------------------------------- - -.. tabs:: - - .. tab:: **Linux/MacOS** - - Set the environment variables `DEPTHAI_WATCHDOG_INITIAL_DELAY` and `DEPTHAI_BOOTUP_TIMEOUT` to your desired timeout values (in milliseconds) as follows: - - .. code-block:: bash - - DEPTHAI_WATCHDOG_INITIAL_DELAY= DEPTHAI_BOOTUP_TIMEOUT= python3 script.py - - .. tab:: **Windows PowerShell** - - For Windows PowerShell, set the environment variables like this: - - .. code-block:: powershell - - $env:DEPTHAI_WATCHDOG_INITIAL_DELAY= - $env:DEPTHAI_BOOTUP_TIMEOUT= - python3 script.py - - .. tab:: **Windows CMD** - - In Windows CMD, you can set the environment variables as follows: - - .. code-block:: guess - - set DEPTHAI_WATCHDOG_INITIAL_DELAY= - set DEPTHAI_BOOTUP_TIMEOUT= - python3 script.py - -Alternatively, you can set the timeout directly in your code: - -.. code-block:: python - - pipeline = depthai.Pipeline() - - # Create a BoardConfig object - config = depthai.BoardConfig() - - # Set the parameters - config.watchdogInitialDelayMs = - config.watchdogTimeoutMs = - - pipeline.setBoardConfig(config) - -By adjusting these settings, you can tailor the watchdog functionality to better suit your specific requirements. - - -Environment Variables -##################### - -The following table lists various environment variables used in the system, along with their descriptions: - -.. list-table:: - :widths: 50 50 - :header-rows: 1 - - * - Environment Variable - - Description - * - `DEPTHAI_LEVEL` - - Sets logging verbosity, options: 'trace', 'debug', 'warn', 'error', 'off' - * - `XLINK_LEVEL` - - Sets logging verbosity of XLink library, options: 'debug', 'info', 'warn', 'error', 'fatal', 'off' - * - `DEPTHAI_INSTALL_SIGNAL_HANDLER` - - Set to 0 to disable installing Backward signal handler for stack trace printing - * - `DEPTHAI_WATCHDOG` - - Sets device watchdog timeout. Useful for debugging (DEPTHAI_WATCHDOG=0), to prevent device reset while the process is paused. - * - `DEPTHAI_WATCHDOG_INITIAL_DELAY` - - Specifies delay after which the device watchdog starts. - * - `DEPTHAI_SEARCH_TIMEOUT` - - Specifies timeout in milliseconds for device searching in blocking functions. - * - `DEPTHAI_CONNECT_TIMEOUT` - - Specifies timeout in milliseconds for establishing a connection to a given device. - * - `DEPTHAI_BOOTUP_TIMEOUT` - - Specifies timeout in milliseconds for waiting the device to boot after sending the binary. - * - `DEPTHAI_PROTOCOL` - - Restricts default search to the specified protocol. Options: any, usb, tcpip. - * - `DEPTHAI_DEVICE_MXID_LIST` - - Restricts default search to the specified MXIDs. Accepts comma separated list of MXIDs. Lists filter results in an "AND" manner and not "OR" - * - `DEPTHAI_DEVICE_ID_LIST` - - Alias to MXID list. Lists filter results in an "AND" manner and not "OR" - * - `DEPTHAI_DEVICE_NAME_LIST` - - Restricts default search to the specified NAMEs. Accepts comma separated list of NAMEs. Lists filter results in an "AND" manner and not "OR" - * - `DEPTHAI_DEVICE_BINARY` - - Overrides device Firmware binary. Mostly for internal debugging purposes. - * - `DEPTHAI_BOOTLOADER_BINARY_USB` - - Overrides device USB Bootloader binary. Mostly for internal debugging purposes. - * - `DEPTHAI_BOOTLOADER_BINARY_ETH` - - Overrides device Network Bootloader binary. Mostly for internal debugging purposes. - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.Device - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::Device - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../includes/footer-short.rst diff --git a/docs/source/components/messages.rst b/docs/source/components/messages.rst deleted file mode 100644 index 7130d0147..000000000 --- a/docs/source/components/messages.rst +++ /dev/null @@ -1,62 +0,0 @@ -.. _components_messages: - -Messages -======== - -Messages are sent between linked :ref:`Nodes`. The only way nodes communicate with each other is by sending messages from one to another. On the -table of contents (left side of the page) **all DepthAI messages are listed** under the :code:`Messages` entry. You can click on them to find out more. - -.. rubric:: Creating a message in Script node - -A DepthAI message can be created either on the device, by a node automatically or manually inside the :ref:`Script` node. In below example, -the code is taken from the :ref:`Script camera control` example, where :ref:`CameraControl` is created inside the Script node every second -and sent to the :ref:`ColorCamera`'s input (:code:`cam.inputControl`). - -.. code-block:: python - - script = pipeline.create(dai.node.Script) - script.setScript(""" - # Create a message - ctrl = CameraControl() - # Configure the message - ctrl.setCaptureStill(True) - # Send the message from the Script node - node.io['out'].send(ctrl) - """) - -.. rubric:: Creating a message on a Host - -It can also be created on a host computer and sent to the device via :ref:`XLinkIn` node. :ref:`RGB Camera Control`, :ref:`Video & MobilenetSSD` -and :ref:`Stereo Depth from host` code examples demonstrate this functionality perfectly. In the example below, we have removed all the code -that isn't relevant to showcase how a message can be created on the host and sent to the device via XLink. - -.. code-block:: python - - # Create XLinkIn node and configure it - xin = pipeline.create(dai.node.XLinkIn) - xin.setStreamName("frameIn") - xin.out.link(nn.input) # Connect it to NeuralNetwork's input - - with dai.Device(pipeline) as device: - # Create input queue, which allows you to send messages to the device - qIn = device.getInputQueue("frameIn") - # Create ImgFrame message - img = dai.ImgFrame() - img.setData(frame) - img.setWidth(300) - img.setHeight(300) - qIn.send(img) # Send the message to the device - -.. rubric:: Creating a message on an external MCU - -A message can also be created on an external MCU and sent to the device via :ref:`SPIIn` node. An demo of such functionality is the -`spi_in_landmark `__ example. - -.. toctree:: - :maxdepth: 0 - :hidden: - :glob: - - messages/* - -.. include:: ../includes/footer-short.rst diff --git a/docs/source/components/messages/buffer.rst b/docs/source/components/messages/buffer.rst deleted file mode 100644 index 551d496a4..000000000 --- a/docs/source/components/messages/buffer.rst +++ /dev/null @@ -1,26 +0,0 @@ -Buffer -====== - -Just a good old buffer. All other messages derive from the :code:`Buffer` class. - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.Buffer - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::Buffer - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/camera_control.rst b/docs/source/components/messages/camera_control.rst deleted file mode 100644 index 05d181840..000000000 --- a/docs/source/components/messages/camera_control.rst +++ /dev/null @@ -1,35 +0,0 @@ -CameraControl -============= - -This message is used for controlling the :ref:`color camera ` as well as the :ref:`mono camera `. -The message handles things like capturing still images, configuring auto focus, anti banding, white balance, -scenes, effects etc. - -Examples of functionality -######################### - -- :ref:`RGB Camera Control` -- :ref:`Mono Camera Control` -- :ref:`Auto Exposure on ROI` - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.CameraControl - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::CameraControl - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/edge_detector_config.rst b/docs/source/components/messages/edge_detector_config.rst deleted file mode 100644 index dd1aae70e..000000000 --- a/docs/source/components/messages/edge_detector_config.rst +++ /dev/null @@ -1,32 +0,0 @@ -EdgeDetectorConfig -================== - -This message is used to configure the :ref:`EdgeDetector` node. -You can set the horizontal and vertical Sobel filter kernel. - -Examples of functionality -######################### - -- :ref:`Edge detector` - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.EdgeDetectorConfig - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::EdgeDetectorConfig - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/encoded_frame.rst b/docs/source/components/messages/encoded_frame.rst deleted file mode 100644 index e2aee05e2..000000000 --- a/docs/source/components/messages/encoded_frame.rst +++ /dev/null @@ -1,54 +0,0 @@ -EncodedFrame -============ - -The ``EncodedFrame`` message is an output of the :ref:`VideoEncoder` node. This message is used to represent a frame that has been encoded by the VideoEncoder. It provides various properties and methods for interacting with the encoded frame data. - -Structure -######### - -The ``EncodedFrame`` class inherits from ``Buffer`` and includes several nested classes and methods for accessing and modifying frame properties. Here are the primary components of the ``EncodedFrame`` class: - -- ``FrameType``: Enumerates the types of frames that can be encoded (I, P, B, Unknown). -- ``Profile``: Indicates the encoding profile used (AVC, HEVC, JPEG). - -FrameType ---------- - -The ``FrameType`` class identifies the type of the encoded frame. The available types are: - -- **B**: Represents a bi-directional predicted frame. -- **I**: Represents an intra-coded frame. -- **P**: Represents a predicted frame. -- **Unknown**: Used when the frame type cannot be determined. - -Profile -------- - -The ``Profile`` class specifies the encoding profile used for the frame. The supported profiles are: - -- **AVC**: H.264/AVC encoding profile. -- **HEVC**: H.265/HEVC encoding profile. -- **JPEG**: JPEG encoding profile. - - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.EncodedFrame - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::EncodedFrame - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/feature_tracker_config.rst b/docs/source/components/messages/feature_tracker_config.rst deleted file mode 100644 index 053409c1f..000000000 --- a/docs/source/components/messages/feature_tracker_config.rst +++ /dev/null @@ -1,27 +0,0 @@ -FeatureTrackerConfig -==================== - -This message is used to configure the :ref:`FeatureTracker` node. -You can set the CornerDetector, FeatureMaintainer and MotionEstimator. - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.FeatureTrackerConfig - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::FeatureTrackerConfig - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/image_manip_config.rst b/docs/source/components/messages/image_manip_config.rst deleted file mode 100644 index 5535536f5..000000000 --- a/docs/source/components/messages/image_manip_config.rst +++ /dev/null @@ -1,35 +0,0 @@ -ImageManipConfig -================ - -This message can is used for cropping, warping, rotating, resizing, etc. an image in runtime. -It can be sent from host/:ref:`Script` node to either :ref:`ColorCamera` or :ref:`ImageManip`. - -.. note:: This message will reconfigure the whole config of the node, meaning you need to set all settings, not just the setting you want to change. - -Examples of functionality -######################### - -- :ref:`RGB Camera Control` -- :ref:`RGB Rotate Warp` - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.ImageManipConfig - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::ImageManipConfig - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/img_detections.rst b/docs/source/components/messages/img_detections.rst deleted file mode 100644 index afca0df55..000000000 --- a/docs/source/components/messages/img_detections.rst +++ /dev/null @@ -1,34 +0,0 @@ -ImgDetections -============= - -Both :ref:`YoloDetectionNetwork` and :ref:`MobileNetDetectionNetwork` output this message. This message contains a list of :code:`detections`, -which contains :code:`label`, :code:`confidence`, and the bounding box information (:code:`xmin`, :code:`ymin`, :code:`xmax`, :code:`ymax`). - -Examples of functionality -######################### - -- :ref:`RGB & MobilenetSSD` -- :ref:`Mono & MobilenetSSD` -- :ref:`RGB & Tiny YOLO` - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.ImgDetections - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::ImgDetections - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/img_frame.rst b/docs/source/components/messages/img_frame.rst deleted file mode 100644 index ac7302515..000000000 --- a/docs/source/components/messages/img_frame.rst +++ /dev/null @@ -1,34 +0,0 @@ -ImgFrame -======== - -These are all the images (regardless of their encoding/format), as well as the depth/disparity "image". :ref:`ColorCamera` and -:ref:`MonoCamera` are the source of the image frame messages. - -Examples of functionality -######################### - -- :ref:`RGB Preview` -- :ref:`Mono Preview` -- :ref:`Depth Preview` - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.ImgFrame - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::ImgFrame - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/imu_data.rst b/docs/source/components/messages/imu_data.rst deleted file mode 100644 index caee03085..000000000 --- a/docs/source/components/messages/imu_data.rst +++ /dev/null @@ -1,26 +0,0 @@ -IMUData -======= - -IMU data message is created by the :ref:`IMU` node. - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.IMUData - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::IMUData - :project: depthai-core - :members: - :private-members: - :undoc-members: - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/message_group.rst b/docs/source/components/messages/message_group.rst deleted file mode 100644 index e947ad67d..000000000 --- a/docs/source/components/messages/message_group.rst +++ /dev/null @@ -1,32 +0,0 @@ -MessageGroup -============ - -The MessageGroup message type is a versatile container used in DepthAI pipelines to group together a map of arbitrary DepthAI messages. It serves as the primary output of the :ref:`Sync` node, effectively synchronizing various input streams, and acts as the input to the :ref:`MessageDemux` node for subsequent disaggregation and processing. - -Creating MessageGroup -##################### - -MessageGroup can be created automatically by the Sync node as it aligns and groups messages from different sources based on their timestamps. Alternatively, it can be manually constructed in a host application or within a :ref:`Script` node to create custom groupings of DepthAI messages. - -Reference -######### - -.. tabs:: - - .. tab:: Python - - .. autoclass:: depthai.MessageGroup - :members: - :inherited-members: - :noindex: - - .. tab:: C++ - - .. doxygenclass:: dai::MessageGroup - :project: depthai-core - :members: - :private-members: - :undoc-members: - - -.. include:: ../../includes/footer-short.rst diff --git a/docs/source/components/messages/nn_data.rst b/docs/source/components/messages/nn_data.rst deleted file mode 100644 index cef6922ae..000000000 --- a/docs/source/components/messages/nn_data.rst +++ /dev/null @@ -1,33 +0,0 @@ -NNData -====== - -This message carries tensors and its data. :ref:`NeuralNetwork` node outputs NNData. - -Creating NNData -############### - -You can also create this message on the host (`example here `__) -or :ref:`Script` node (:ref:`example here