Hi,
Tensorflow is used mainly to create, train and execute Neural Network. The operations you need can be easily done with some network libraries, such as the Boost ones. I don't know if I fully understood the requirements, anyway I worked with Keras and Tensorflow many times, if you want you can PM me.
Best regards,
Davide