SMAC is written in python3 and therefore requires an environment with python>=3.8. Furthermore, the Random Forest used in SMAC requires SWIG as a build dependency.
!!! info
SMAC is tested on Linux and Mac machines with python >=3.8.
We recommend using Anaconda to create and activate an environment:
conda create -n SMAC python=3.10
conda activate SMAC
Now install swig either on the system level e.g. using the following command for Linux:
apt-get install swig
Or install swig inside of an already created conda environment using:
conda install gxx_linux-64 gcc_linux-64 swig
You can install SMAC either using PyPI or Conda-forge.
To install SMAC with PyPI call:
pip install smac
Or alternatively, clone the environment from GitHub directly:
git clone https://github.com/automl/SMAC3.git && cd SMAC3
pip install -e ".[dev]"
Installing SMAC from the conda-forge
channel can be achieved by adding conda-forge
to your channels with:
conda config --add channels conda-forge
conda config --set channel_priority strict
You must have conda >= 4.9
installed. To update conda or check your current conda version, please follow the instructions from the official anaconda documentation. Once the conda-forge
channel has been enabled, SMAC can be installed with:
conda install smac
Read SMAC feedstock for more details.
SMAC can be installed under Windows in a WSL (Windows Subsystem for Linux). You can find an instruction on how to do this here: Experimental. However, this is experimental and might not work in each case. If you would like to suggest any changes, please let us know.