Investigation of the radiation damage of GaAs detectors by neutrons and photons