Trace forms of G-Galois algebras in virtual cohomological dimension 1 and 2