Jutho / TensorOperations.jl

Julia package for tensor contractions and related operations
https://jutho.github.io/TensorOperations.jl/stable/
Other
438 stars 55 forks source link

Switch up argument order #173

Closed lkdvos closed 1 month ago

lkdvos commented 1 month ago

This changes the argument order of the interface functions to the following:

tensorcontract!(C, A, pA, conjA, B, pB, conjB, pAB, alfa, beta, backend) # beta * C + alfa * permutedims(permutedims(A, pA) * permutedims(B, pB), pAB)
tensoradd!(C, A, pA, conjA, alfa, beta, backend) # beta * C + alfa * permutedims(A, pA)
tensortrace!(C, A, p, q, conjA, alfa, beta, backend) # beta * C + alfa * permuteandtracedims(A, p, q)
tensorcopy([IC], A, IA, [conjA,] [alfa,] [backend])
tensoradd([IC], A, IA, [conjA,] B, IB, [conjB,] [alfa, beta,] [backend])
tensortrace([IC], A, IA, [conjA], [alfa], [backend])
tensorcontract([IC], A, IA, [conjA], B, IB, [conjB], [alfa,] [backend])
tensorproduct([IC], A, IA, [conjA], B, IB, [conjB], [alfa,] [backend])

with the exclusion of the cutensor extension, due to the imminent changes from cuTensor v2