A software package for analyzing Calabi-Yau manifolds
CYTools is an open-source software package developed by Liam McAllister's group with the purpose of studying Calabi-Yau manifolds arising from the Kreuzer-Skarke database. The founding authors are Mehmet Demirtas and Andres Rios-Tascon; the current BDFL is Nate MacFadden. It emerged from several years of effort towards exploring previously uncharted parts of the string landscape. It offers vastly superior computational performance compared to other software that are typically used in the field, as discussed in the CYTools paper arXiv:2211.03823. Installation instructions and detailed documentation can be found in the CYTools website.
Most of the code is written in Python, with wrappers to interface with various other open-source software. It is distributed as a Python package that can be installed with pip or conda, which pull in the necessary dependencies so that it is easy to install and use on most operating systems.
- Polytopes and triangulations. Lattice point enumeration, face lattices, cone computations, and fine regular star triangulations, along with utilities to fetch reflexive polytopes from the Kreuzer-Skarke database (
cytools.fetch_polytopes). - Calabi-Yau hypersurfaces. Hodge numbers, intersection numbers, Mori and Kähler cones, divisor and Calabi-Yau volumes, second Chern class, and Gopakumar-Vafa invariants.
- NTFE enumeration. Enumeration and sampling of the expanded secondary cones and the corresponding FR(S)Ts of a polytope, following arXiv:2309.10855 (
cytools.ntfe). - GNN triangulation sampling. Near-uniform sampling of NTFE FR(S)Ts using the dualGNN graph neural network (arXiv:2605.27770) to sample the 2-face triangulations (
Polytope.random_triangulations_gnn). This requires the optionaldualgnnpackage:pip install cytools[gnn], or seeenvironment-gnn.yml. - F-theory tooling. Orientifolds and F-theory uplifts of Calabi-Yau hypersurfaces (
cytools.f_theory).
After installing CYTools, compute the Hodge numbers of the quintic Calabi-Yau threefold:
from cytools import Polytope
p = Polytope([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1], [-1, -1, -1, -1]])
cy = p.triangulate().get_cy()
print(cy.h11(), cy.h21()) # 1 101If you use CYTools in your work, please cite the CYTools paper, CYTools: A Software Package for Analyzing Calabi-Yau Manifolds (arXiv:2211.03823). Machine-readable citation metadata is available in CITATION.cff.
CYTools makes use of a variety of open-source projects. It includes a few code snippets from SageMath [GPLv2], a modified version of TOPCOM [GPLv2] that can be found here, the Computational Geometry Algorithms Library [LGPLv3], and multiple Python packages including SciPy, NumPy, pplpy, OR-Tools, scikit-sparse, and flint-py.
All original CYTools code is distributed under the terms of the GNU General Public License version 3. All other packages and code snippets are redistributed under their respective licenses.
Questions, comments and/or suggestions can be directed to support@cy.tools.
