Structure verification of deep neural networks at compilation time