A neural network approach is used to reconstruct surface-induced refractive-index profiles from angular and wavelength spectra from ellipsometric signals. The performance of the method is assessed using a large set of simulated profiles in a wide, parametrized profile space. The neural network optical profile recognition technique is applied to data of ellipsometric measurements on a liquid-crystal sample in the isotropic phase, which is inhomogeneously aligned at the surface because of surface-induced pre-nematic ordering in the vicinity of the isotropic - nematic phase-transition temperature.