IsRecompute接口
接口功能
判断请求是否是重计算请求。
接口格式
bool IsRecompute() const;
接口参数
无。
使用样例
首先构造一个请求对象,然后为该请求对象设置重计算类型,最后获取该请求是否为重计算请求。
1 2 3 4 | mindie_llm::InferRequestId runtimeReqId(0); std::shared_ptr<mindie_llm::InferRequest> runtimeRequest(runtimeReqId); runtimeRequest->SetRecompute(true); bool isRecompute = runtimeRequest->IsRecompute(); |
返回值
bool类型。
父主题: InferRequest