-
Notifications
You must be signed in to change notification settings - Fork 14
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
Integration with Matrex #17
Comments
Performance consideration on data transfer from Matrex into TensorFlow.Matrex stores data in a binary, and it's possible to pass that binary into TF. So now we have to copy that binary into another one allocated with It would be nice if we could just increase reference counter for that binary, when passing into TF and decrease it back, when TF calls our deallocator. |
@versilov can you create a reference to the binary using sub binaries and keep it around and erase the reference once you are done with the TF call? More info: http://erlang.org/doc/man/erl_nif.html#enif_make_sub_binary |
Nice idea! Will try today. |
@versilov I have tried using the However, the general Matrex package compiles just fine. Any dependencies included in the C Here is the output log:
|
Yes, it's still in development. Sorry for that. |
No problem. I can use the main package to integrate with Tensorflex then? Or is it missing some functionalities? |
@josevalim I can make a sub-binary, but I could not find how to release it. |
@anshuman23 it misses two main things: arbitrary dimensions and different types (it's hardcoded for 2-dimensional float matrices.). |
@versilov maybe ask around in the Erlang Questions mailing list? |
I've sent it into Erlang mailing list. |
I can see two ways for integration:
tensor_from_matrex/1
to derive tensors from Matrex objects.My suggestion is to go with the loose method for now and to consider tight integration in some experimental branch.
The text was updated successfully, but these errors were encountered: