"Tensor methods for path integrals and lattice gauge theories”