Topological obstructions in neural networks learning