Pipeline
Pipeline
Pipeline 入门
Python
1pipeline = depthai.pipeline()
2
3# 如果需要,指定 OpenVINO 版本
4pipeline.setOpenVINOVersion(depthai.OpenVINO.Version.VERSION_2021_4)
5
6# 创建节点,配置它们并将它们链接在一起
7
8# 将 pipeline 上传到设备
9with depthai.Device(pipeline) as device:
10 # 设置输入/输出队列以通过 XLink 配置设备/主机通信...指定 OpenVINO 版本
Python
1pipeline = depthai.pipeline()
2# 设置正确的版本:
3pipeline.setOpenVINOVersion(depthai.OpenVINO.Version.VERSION_2021_4)使用多个设备
如何放置它
Python
Python
1pipeline = dai.Pipeline()参考
class
depthai.Pipeline
method
__init__(self)Constructs a new pipeline
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
method
getBoardConfig(self) -> BoardConfig: BoardConfigGets board configuration
method
getCalibrationData(self) -> CalibrationHandler: CalibrationHandlergets the calibration data which is set through pipeline Returns: the calibrationHandler with calib data in the pipeline
method
getConnectionMap(self) -> dict[int, set[Node.Connection]]: dict[int, set[Node.Connection]]Get a reference to internal connection representation
method
getConnections(self) -> list[Node.Connection]: list[Node.Connection]Get all connections
method
getDeviceConfig(self) -> Device.Config: Device.ConfigGet device configuration needed for this pipeline
method
getGlobalProperties(self) -> GlobalProperties: GlobalPropertiesReturns: Global properties of current pipeline
method
method
getNodeMap(self) -> dict[int, Node]: dict[int, Node]Get a reference to internal node map
method
getOpenVINOVersion(self) -> OpenVINO.Version: OpenVINO.VersionGet possible OpenVINO version to run this pipeline
method
getRequiredOpenVINOVersion(self) -> depthai.OpenVINO.Version|None: depthai.OpenVINO.Version|NoneGet required OpenVINO version to run this pipeline. Can be none
method
link(self, arg0: Node.Output, arg1: Node.Input)Link output to an input. Both nodes must be on the same pipeline Throws an error if they aren't or cannot be connected Parameter ``out``: Nodes output to connect from Parameter ``in``: Nodes input to connect to
method
remove(self, node: Node)Removes a node from pipeline
method
serializeToJson(self) -> json: jsonReturns whole pipeline represented as JSON
method
setBoardConfig(self, arg0: BoardConfig)Sets board configuration
method
setCalibrationData(self, calibrationDataHandler: CalibrationHandler)Sets the calibration in pipeline which overrides the calibration data in eeprom Parameter ``calibrationDataHandler``: CalibrationHandler object which is loaded with calibration information.
method
setCameraTuningBlobPath(self, path: Path)Set a camera IQ (Image Quality) tuning blob, used for all cameras
method
setOpenVINOVersion(self, version: OpenVINO.Version)Set a specific OpenVINO version to use with this pipeline
method
setSippBufferSize(self, sizeBytes: typing.SupportsInt)SIPP (Signal Image Processing Pipeline) internal memory pool. SIPP is a framework used to schedule HW filters, e.g. ISP, Warp, Median filter etc. Changing the size of this pool is meant for advanced use cases, pushing the limits of the HW. By default memory is allocated in high speed CMX memory. Setting to 0 will allocate in DDR 256 kilobytes. Units are bytes.
method
setSippDmaBufferSize(self, sizeBytes: typing.SupportsInt)SIPP (Signal Image Processing Pipeline) internal DMA memory pool. SIPP is a framework used to schedule HW filters, e.g. ISP, Warp, Median filter etc. Changing the size of this pool is meant for advanced use cases, pushing the limits of the HW. Memory is allocated in high speed CMX memory Units are bytes.
method
setXLinkChunkSize(self, sizeBytes: typing.SupportsInt)Set chunk size for splitting device-sent XLink packets, in bytes. A larger value could increase performance, with 0 disabling chunking. A negative value won't modify the device defaults - configured per protocol, currently 64*1024 for both USB and Ethernet.
method
unlink(self, arg0: Node.Output, arg1: Node.Input)Unlink output from an input. Throws an error if link doesn't exists Parameter ``out``: Nodes output to unlink from Parameter ``in``: Nodes input to unlink to