Setup and installation
Installing the Carrot MathEngine
This guide details the recommended process for installing the Carrot-MathEngine and all required packages using the setuptools standard package.
Step 1: Create and Activate a Virtual Environment
It's recommended to use a virtual environment to manage dependencies. Using the Virtual Environment manager (venv), install Python version >=3.12 using:
Activate the virtual environment:
- Windows:
- macOS/Linux:
Step 2: Install Dependencies
Use pip to install dependencies from the requirements.txt file:
Step 3: Install the Package in Editable Mode
Using the setup.py file, the package should be installed it in editable mode (for development purposes) with the command:
This allows modifications to the package source code to take effect without reinstallation.
Step 4: Verify Installation
You can check that the package is installed by running:
or testing the package import in Python:
Deactivating the Virtual Environment
When finished, deactivate the virtual environment with:
Installing Cargo
If the optimization algorithm is being utilized, Rust and Cargo should be installed.