|
1 | | -.. Basilisk documentation master file, created by |
2 | | - sphinx-quickstart on Mon Sep 23 13:52:19 2019. |
3 | | - You can adapt this file completely to your liking, but it should at least |
4 | | - contain the root `toctree` directive. |
5 | | -
|
6 | 1 | .. _bskInstall: |
7 | 2 |
|
8 | 3 | Install |
9 | 4 | ======= |
10 | 5 |
|
11 | | -.. toctree:: |
12 | | - :maxdepth: 1 |
13 | | - :caption: Contents: |
| 6 | +Basilisk can be installed either from `PyPI <https://pypi.org/project/bsk/>`_ as |
| 7 | +a prebuilt wheel or built locally from source. |
| 8 | +The prebuilt wheels include all build options, such as optical navigation |
| 9 | +and MuJoCo dynamics, but do **not** support linking external C++ modules, as |
| 10 | +this requires rebuilding Basilisk. |
| 11 | + |
| 12 | +If you want to use custom C++ modules, or prefer smaller install sizes by |
| 13 | +excluding unused features, you must build Basilisk from source. |
| 14 | +See the :ref:`Building from Source <bskInstall-build>` for more information. |
| 15 | + |
| 16 | +.. note:: |
| 17 | + We are currently investigating ways to allow users to link external C++ |
| 18 | + modules while using the prebuilt PyPI wheel. Stay tuned! |
| 19 | + |
| 20 | + |
| 21 | +The easiest way to install Basilisk is using ``pip`` to install the prebuilt |
| 22 | +package from PyPI. Run: |
| 23 | + |
| 24 | +.. code-block:: bash |
| 25 | +
|
| 26 | + pip install bsk |
| 27 | +
|
| 28 | +Or, if using `uv <https://docs.astral.sh/uv/>`_ (a modern Python package manager): |
| 29 | + |
| 30 | +.. code-block:: bash |
| 31 | +
|
| 32 | + uv pip install bsk |
| 33 | +
|
| 34 | +This installs the latest stable version of Basilisk and all dependencies. |
| 35 | +To install a specific version, run: |
| 36 | + |
| 37 | +.. code-block:: bash |
| 38 | +
|
| 39 | + pip install bsk==<version> |
| 40 | +
|
| 41 | +Replace ``<version>`` with the desired release number, e.g. ``2.0.0``. |
| 42 | + |
| 43 | + |
| 44 | +**Prebuilt wheel availability:** |
| 45 | + |
| 46 | +- **Windows:** Windows 10/11 (x86_64) |
| 47 | +- **macOS:** macOS 11+ (x86_64 and Apple Silicon arm64) |
| 48 | +- **Linux:** Manylinux 2.24+ (x86_64, aarch64) |
| 49 | + |
| 50 | +All wheels are built as **ABI3** packages for Basilisk supported Python |
| 51 | +versions. |
| 52 | + |
| 53 | +.. note:: |
| 54 | + On unsupported systems or Python versions, ``pip`` will automatically |
| 55 | + download the source archive (``.tar.gz``) and build Basilisk locally. |
| 56 | + This requires a C++ compiler toolchain and standard build tools |
| 57 | + to be installed on your system. |
| 58 | + |
| 59 | +To keep the wheel size smaller, the large BSK data files are not installed by |
| 60 | +default. If the user wants to use script that assumes they are included into |
| 61 | +the Basilisk python package, then go to the command line, change the current |
| 62 | +directory to be inside the environment where Basilisk was ``pip`` installed, |
| 63 | +and run the command:: |
| 64 | + |
| 65 | + bskLargeData |
| 66 | + |
| 67 | +This command runs a python file stored in the ``src/utilities`` folder. |
| 68 | +The ``pip install`` process automatically |
| 69 | +creates this console command in the current python environment to call this |
| 70 | +python file. The file directly downloads the missing large BSK data files and put |
| 71 | +them into the local Basilisk python package installation. |
0 commit comments