faster implementation of TensorManager
small changes in the documentation