-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rkllm_run_async 无效 #208
Comments
你好,不使用异步时能否正常推理呢。 |
/rknn-llm-main/rkllm-runtime/Linux/librkllm_api/include/rkllm.h int rkllm_run(LLMHandle handle, RKLLMInput* rkllm_input, RKLLMInferParam* rkllm_infer_params, void* userdata); /**
/**
我看rkllm_run_async函数实际上是Aborts an ongoing LLM task。rkllm_run虽然可以正常推理,但是无法并行,以提升npu利用率 |
你好,不使用异步时可以正常推理,callback有回调 |
我也遇到了 解决了嘛大佬 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
参考llm_demo,在RK3588平台上,初始化参数RKLLMParam的is_async设置为true,调用rkllm_run_async,
`
RKLLMInput rkllm_input;
RKLLMInferParam rkllm_infer_params;
memset(&rkllm_infer_params, 0, sizeof(RKLLMInferParam));
rkllm_infer_params.mode = RKLLM_INFER_GENERATE;
rkllm_input.input_type = RKLLM_INPUT_PROMPT;
rkllm_input.prompt_input = (char *)text.c_str();
rkllm_run_async(llmHandle, &rkllm_input, &rkllm_infer_params, NULL);
`
在初始化的回调函数(callback(RKLLMResult *result, void *userdata, LLMCallState state))中,没有收到任何数据,请问还有什么参数需要设置吗?
The text was updated successfully, but these errors were encountered: