You are viewing a plain text version of this content. The canonical link for it is here.
Posted to discuss-archive@tvm.apache.org by Max Sponner via TVM Discuss <no...@discuss.tvm.ai> on 2020/09/02 12:38:27 UTC
[TVM Discuss] [Questions] BYOC: Runtime access Tensor values
Hi,
I am working on a BYOC backend and finally reached the runtime level.
But I've looked at the DNNL JSON example (I am using JSON as well) and have not found
a way to access the real tensor values to serialize them for my target.
From the JSON serialization I can access the shapes, etc, but not the data.
Where do I have to look for that?
---
[Visit Topic](https://discuss.tvm.ai/t/byoc-runtime-access-tensor-values/7802/1) to respond.
You are receiving this because you enabled mailing list mode.
To unsubscribe from these emails, [click here](https://discuss.tvm.ai/email/unsubscribe/0ca7066fcd78f51d6d484ca06078a706483e4db290d5efecf791358851479488).
[TVM Discuss] [Questions] BYOC: Runtime access Tensor values
Posted by "Cody H. Yu via TVM Discuss" <no...@discuss.tvm.ai>.
Here is an example of Zhi's response. The expression `data_entry_[eid]->data` accesses the values of the tesnor.
https://github.com/apache/incubator-tvm/blob/master/src/runtime/contrib/dnnl/dnnl_json_runtime.cc#L71
---
[Visit Topic](https://discuss.tvm.ai/t/byoc-runtime-access-tensor-values/7802/3) to respond.
You are receiving this because you enabled mailing list mode.
To unsubscribe from these emails, [click here](https://discuss.tvm.ai/email/unsubscribe/a484b9b73c3bc9d90cf7323492ba40c0392a8acf16a3f4256d8b4b1dc7a2f450).
[TVM Discuss] [Questions] BYOC: Runtime access Tensor values
Posted by Zhi via TVM Discuss <no...@discuss.tvm.ai>.
The inputs are passed through NDArray in the DNNL example. You can use nd_array->data to get the data pointer.
---
[Visit Topic](https://discuss.tvm.ai/t/byoc-runtime-access-tensor-values/7802/2) to respond.
You are receiving this because you enabled mailing list mode.
To unsubscribe from these emails, [click here](https://discuss.tvm.ai/email/unsubscribe/a88782c435c77c50d7c59a5e51e586703f472e5f8e3a55bc3d6847d1ce8fe5ff).