Learning on manifolds without manifold learning