Go to the documentation of this file.
6 #include <unordered_set>
50 std::vector<std::shared_ptr<const Node>>
getAllNodes()
const;
57 void remove(std::shared_ptr<Node> node);
74 using NodeMap = std::unordered_map<Node::Id, std::shared_ptr<Node>>;
76 using NodeConnectionMap = std::unordered_map<Node::Id, std::unordered_set<Node::Connection>>;
84 std::shared_ptr<N>
create(
const std::shared_ptr<PipelineImpl>& itself) {
86 static_assert(std::is_base_of<Node, N>::value,
"Specified class is not a subclass of Node");
90 auto node = std::make_shared<N>(itself,
id);
101 std::shared_ptr<PipelineImpl>
pimpl;
114 explicit Pipeline(
const std::shared_ptr<PipelineImpl>&
pimpl);
150 void remove(std::shared_ptr<Node> node) {
void setSippDmaBufferSize(int sizeBytes)
CalibrationHandler getCalibrationData() const
void setBoardConfig(BoardConfig board)
Sets board configuration.
Represents the pipeline, set of nodes and connections between them.
std::shared_ptr< const Node > getNode(Node::Id id) const
std::int64_t Id
Node identificator. Unique for every node on a single Pipeline.
void link(const Node::Output &out, const Node::Input &in)
std::shared_ptr< N > create(const std::shared_ptr< PipelineImpl > &itself)
PipelineImpl::NodeConnectionMap NodeConnectionMap
constexpr static auto DEFAULT_SERIALIZATION_TYPE
std::unordered_map< Node::Id, std::shared_ptr< Node > > NodeMap
const AssetManager & getAssetManager() const
Get pipelines AssetManager as reference.
PipelineSchema getPipelineSchema(SerializationType type=DEFAULT_SERIALIZATION_TYPE) const
Version
OpenVINO Version supported version information.
tl::optional< OpenVINO::Version > getRequiredOpenVINOVersion() const
Get required OpenVINO version to run this pipeline. Can be none.
void remove(std::shared_ptr< Node > node)
Removes a node from pipeline.
std::vector< std::shared_ptr< const Node > > getAllNodes() const
Get a vector of all nodes.
std::shared_ptr< Node > getNode(Node::Id id)
Get node with id if it exists, nullptr otherwise.
constexpr static const Version DEFAULT_VERSION
Main OpenVINO version.
bool isOpenVINOVersionCompatible(OpenVINO::Version version) const
void setCalibrationData(CalibrationHandler calibrationDataHandler)
static bool canConnect(const Node::Output &out, const Node::Input &in)
std::vector< Node::Connection > getConnections() const
Get all connections.
void unlink(const Node::Output &out, const Node::Input &in)
AssetManager & getAssetManager()
Get pipelines AssetManager as reference.
AssetManager can store assets and serialize.
std::shared_ptr< const Node > getNode(Node::Id id) const
Get node with id if it exists, nullptr otherwise.
GlobalProperties getGlobalProperties() const
void setXLinkChunkSize(int sizeBytes)
void setCalibrationData(CalibrationHandler calibrationDataHandler)
void setXLinkChunkSize(int sizeBytes)
OpenVINO::Version getOpenVINOVersion() const
Get possible OpenVINO version to run this pipeline.
nlohmann::json serializeToJson() const
Returns whole pipeline represented as JSON.
nlohmann::json serializeToJson() const
Node::Id getNextUniqueId()
std::vector< std::shared_ptr< Node > > getAllNodes()
Get a vector of all nodes.
std::vector< std::shared_ptr< const Node > > getAllNodes() const
void setOpenVINOVersion(OpenVINO::Version version)
Set a specific OpenVINO version to use with this pipeline.
void serialize(PipelineSchema &schema, Assets &assets, std::vector< std::uint8_t > &assetStorage) const
std::unordered_map< Node::Id, std::unordered_set< Node::Connection > > NodeConnectionMap
std::shared_ptr< N > create()
void setSippBufferSize(int sizeBytes)
void setBoardConfig(BoardConfig board)
BoardConfig getBoardConfig() const
Device::Config getDeviceConfig() const
Get device configuration needed for this pipeline.
tl::optional< OpenVINO::Version > getPipelineOpenVINOVersion() const
void setSippDmaBufferSize(int sizeBytes)
void setCameraTuningBlobPath(const dai::Path &path)
AssetManager assetManager
void setSippBufferSize(int sizeBytes)
GlobalProperties globalProperties
const NodeConnectionMap & getConnectionMap() const
Get a reference to internal connection representation.
void link(const Node::Output &out, const Node::Input &in)
PipelineSchema getPipelineSchema(SerializationType type=DEFAULT_SERIALIZATION_TYPE) const
const NodeMap & getNodeMap() const
Get a reference to internal node map.
bool isOpenVINOVersionCompatible(OpenVINO::Version version) const
Checks whether a given OpenVINO version is compatible with the pipeline.
NodeConnectionMap nodeConnectionMap
const PipelineImpl * impl() const
Device::Config getDeviceConfig() const
std::vector< Node::Connection > getConnections() const
PipelineImpl::NodeMap NodeMap
void setCameraTuningBlobPath(const dai::Path &path)
Set a camera IQ (Image Quality) tuning blob, used for all cameras.
std::shared_ptr< PipelineImpl > pimpl
void remove(std::shared_ptr< Node > node)
void serialize(PipelineSchema &schema, Assets &assets, std::vector< std::uint8_t > &assetStorage, SerializationType type=DEFAULT_SERIALIZATION_TYPE) const
static bool isSamePipeline(const Node::Output &out, const Node::Input &in)
Represents paths on a filesystem; accepts utf-8, Windows utf-16 wchar_t, or std::filesystem::path.
Pipeline clone() const
Clone the pipeline (Creates a copy)
constexpr T value_or(U &&u) const &
Returns the stored value if there is one, otherwise returns u
BoardConfig getBoardConfig() const
Gets board configuration.
tl::optional< OpenVINO::Version > forceRequiredOpenVINOVersion
CalibrationHandler getCalibrationData() const
void unlink(const Node::Output &out, const Node::Input &in)
depthai
Author(s): Martin Peterlin
autogenerated on Sat Mar 22 2025 02:58:19