Hydrogen diffusion and relaxation processes in a-Si:H and a-Ge:H