replacing raw pointers with std::shared_ptr to btas::Tensor