Stress relaxation during annealing of boron nitride films