I will show how geometric invariant theory helps to define a canonical form for arbitrary PEPS, which we call the minimal canonical form. Somehow surprisingly, the construction also gives a new canonical form for MPS. I will comment on some potential applications, in particular to enhance privacy in tensor-network based machine learning.