mindsdb

Is there any way to convert pytorch tensor to tensorflow tensor

我是研究僧i 提交于 2021-02-11 16:39:22
问题 https://github.com/taoshen58/BiBloSA/blob/ec67cbdc411278dd29e8888e9fd6451695efc26c/context_fusion/self_attn.py#L29 I need to use mulit_dimensional_attention from the above link which is implemented in TensorFlow but I am using PyTorch so can I Convert Pytorch Tensor to TensorFlow Tensor or I have to implement it in PyTorch. code which I am trying to use here I have to pass 'rep_tensor' as TensorFlow tensor type but I have PyTorch tensor def multi_dimensional_attention(rep_tensor, rep_mask