Optimization over the embedded submanifold defined by constraints $c(x) = 0$ has attracted much interest over the past few decades due to its wide applications in various areas. Plenty of related optimization packages have been developed based on Riemannian optimization approaches, which rely on some basic geometrical materials of Riemannian manifolds, including retractions, vector transports, etc. These geometrical materials can be challenging to determine in general. Existing packages only accommodate a few well-known manifolds whose geometrical materials are easily accessible. For other manifolds which are not contained in these packages, the users have to develop the geometric materials by themselves. In addition, it is not always tractable to adopt advanced features from various state-of-the-art unconstrained optimization solvers to Riemannian optimization approaches. We introduce CDOpt (available at https://cdopt.github.io/), a user-friendly Python package for a class Riemannian optimization. Based on constraint dissolving approaches, Riemannian optimization problems are transformed into their equivalent unconstrained counterparts in CDOpt. Therefore, solving Riemannian optimization problems through CDOpt directly benefits from various existing solvers and the rich expertise gained over decades for unconstrained optimization. Moreover, all the computations in CDOpt related to any manifold in question are conducted on its constraints expression, hence users can easily define new manifolds in CDOpt without any background on differential geometry. Furthermore, CDOpt extends the neural layers from PyTorch and Flax, thus allows users to train manifold constrained neural networks directly by the solvers for unconstrained optimization. Extensive numerical experiments demonstrate that CDOpt is highly efficient and robust in solving various classes of Riemannian optimization problems.
翻译:基于约束 $c(x) = 0$ 定义的内嵌子流形上的优化问题,因其在多个领域的广泛应用,在过去几十年间引起了极大关注。目前已有大量基于黎曼优化方法的优化包被开发出来,这些方法依赖于黎曼流形的基本几何材料,包括收缩算子、向量传输等。这些几何材料通常难以确定。现有的优化包仅支持少数几个几何材料易于获取的流形。对于未包含在这些包中的其他流形,用户必须自行开发几何材料。此外,将多种最先进无约束优化求解器的先进特性应用于黎曼优化方法并非总是可行的。我们引入CDOpt(可从 https://cdopt.github.io/ 获取),一个针对一类黎曼优化的用户友好型Python包。基于约束消解方法,CDOpt将黎曼优化问题转化为等价的无约束优化问题。因此,通过CDOpt求解黎曼优化问题可直接受益于已有求解器以及数十年来在无约束优化领域积累的丰富经验。此外,CDOpt中与任意流形相关的所有计算均在其约束表达式上执行,因此用户无需微分几何背景即可在CDOpt中轻松定义新流形。进一步地,CDOpt扩展了PyTorch和Flax的神经网络层,使用户能够直接通过无约束优化求解器训练流形约束神经网络。大量数值实验表明,CDOpt在求解各类黎曼优化问题时具有高效率和强鲁棒性。