Class ov::pass::Validate#

class Validate : public ov::pass::ModelPass#

The Validate pass performs sanity checks on attributes and inputs, and computes output shapes and element types for all computation nodes in a given computation graph.

The verification and inference is done via invoking each node’s specific implementation of ov::Node::validate_and_infer_types() function.

By default, the ov::pass::Manager runs this pass after executing every optimization pass. This is to ensure that any update to the graph by an optimization pass does not break the shape and data type requirement on a computation node. This default validation run can be changed via calling the ov::pass::Manager::set_per_pass_validation(bool) function.