A deep learning approach to the structural analysis of proteins