Skip to content

Installation

smopt can be installed from PyPI or directly from source via GitHub.


PyPI

For using the PyPI package in your project, add it to your configuration file:

[project.dependencies]
smopt = "*" # (1)!
  1. Specifying a version is recommended
smopt>=0.1.0

pip

pip install --upgrade --user smopt # (1)!
  1. You may need to use pip3 instead of pip depending on your Python installation.
python -m venv .venv
source .venv/bin/activate
pip install --require-virtualenv --upgrade smopt # (1)!
  1. You may need to use pip3 instead of pip depending on your Python installation.

Note

The command to activate the virtual environment depends on your platform and shell. More info

uv

uv add smopt
uv sync
uv venv
uv pip install smopt

pipenv

pipenv install smopt

poetry

poetry add smopt

pdm

pdm add smopt

hatch

hatch add smopt

GitHub

Install the latest development version directly from the repository:

pip install --upgrade "git+https://github.com/eggzec/smopt.git#egg=smopt"

Building locally

Clone and build from source if you want to modify or test local changes:

git clone https://github.com/eggzec/smopt.git
cd smopt
pip install -e .