|
1 | 1 | # xsuite-kernels |
| 2 | + |
| 3 | +## Simple installation |
| 4 | + |
| 5 | +The package can be installed with `pip install xsuite-kernels`. Since it is |
| 6 | +dependent on particular versions of the Xsuite packages, installing it might |
| 7 | +automatically update your Xsuite packages to newer versions. You can use the |
| 8 | +`-U` option to upgrade all packages to the latest versions. |
| 9 | + |
| 10 | +This package provides a set of precompiled kernels for the Xsuite packages, so |
| 11 | +that commonly used tracking scenarios can be run without the need to compile |
| 12 | +the kernels on the target machine. The precompiled kernels are distributed as |
| 13 | +binary Python wheels of the package `xsuite-kernels` on PyPI. |
| 14 | + |
| 15 | +When the package is installed on a supported machine `pip` will automatically |
| 16 | +download the appropriate kernel files and install them in the correct location, |
| 17 | +so that Xtrack can use them. If `xsuite-kernels` is not installed, Xtrack will |
| 18 | +fall back to the default behaviour of compiling the kernels on the fly. |
| 19 | + |
| 20 | +If the package is installed from source (e.g. by cloning the repository or |
| 21 | +downloading the source distribution in case of an unsupported platform), the |
| 22 | +kernels will be compiled automatically during the installation process |
| 23 | +(see `setup.py`). |
| 24 | + |
| 25 | +## Developer notes |
| 26 | + |
| 27 | +In case of a source installation, the building process can be skipped by setting |
| 28 | +an environment variable `SKIP_KERNEL_BUILD` to `1` before running `pip install`. |
| 29 | + |
| 30 | +If your local versions of `xtrack`, `xfields`, etc. have diverged from the |
| 31 | +versions specified in `pyproject.toml`, you can install the package with the |
| 32 | +`--no-deps` option to avoid upgrading the dependencies. |
| 33 | + |
| 34 | +The package exposes a `xsuite-kernels` command that can be used to manage the |
| 35 | +kernels on demand (add `--help` option for more information): |
| 36 | + |
| 37 | +```bash |
| 38 | +$ xsuite-kernels regenerate # Regenerate all kernels |
| 39 | +$ xsuite-kernels clean # Remove all kernels |
| 40 | +$ xsuite-kernels info # Print some useful debug information |
| 41 | +``` |
0 commit comments