#pragma once #include #include #include #include namespace torch::nativert { class HigherOrderKernel : public OpKernel { enum class OpType { UNKNOWN, COND, WHILE_LOOP, RUN_CONST_GRAPH, }; public: HigherOrderKernel( const Node* node, std::vector> graphExecutors); void computeInternal(ExecutionFrame& executionFrame) const final; private: std::vector> graphExecutors_; OpType opType_; }; } // namespace torch::nativert