I have two 2-D tensors and want to have Cartesian product of them. By Cartesian, I mean the concat of every row of first tensor with every row of second tensor. For example:
Input:
[[1,2,3],[4,5,6]]
and
[[7,8],[9,10]]
Output:
[[1,2,3,7,8],
[1,2,3,9,10],
[4,5,6,7,8],
[4,5,6,9,10]]
I've seen this post, but it doesn't work for this case. What is the best for it?
Thanks