-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[BYOC][COREML] Handle one symbol for each runtime #5989
Conversation
stream->Write(symbol_); | ||
stream->Write((uint64_t)[dirData length]); | ||
stream->Write([dirData bytes], [dirData length]); | ||
LOG(INFO) << "Save " << symbol_ << " (" << [dirData length] << " bytes)"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change to DLOG?
|
||
// TODO: Support multiple outputs. | ||
NDArray out = model.GetOutput(0); | ||
NDArray out = model_->GetOutput(0); | ||
if (args[args.size() - 1].type_code() == kTVMDLTensorHandle) { | ||
DLTensor* arg = args[args.size() - 1]; | ||
out.CopyTo(arg); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are the ndarrays allocated by the host for both inputs and outputs? If so, I think we might be able to do zero copy (in a separate PR).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, will do it in the next PR :)
Thanks @kazum |
* [BYOC][COREML] Handle one symbol for each runtime * LOG -> DLOG
* [BYOC][COREML] Handle one symbol for each runtime * LOG -> DLOG
It's no longer necessary to handle multiple subgraphs in one runtime thanks to the change of #5770, which simplifies the CoreML runtime a bit.
@zhiics @mbaret @FrozenGene Please help this to review.