Efficient parametrization of multi-domain deep neural networks