Installation of PyPop7

In order to install pypop7, it is highly recommended to use the Python3-based virtual environment via venv or conda. Anaconda (or its mini version miniconda) is a very popular Python programming platform of scientists and researchers especially for artificial intelligence (AI) / machine learning (ML) / data science (DS).

Pip via Python Package Index (PyPI)

Note that pip is the package installer for Python. You can use it to install various packages easily. For pypop7, please run the following shell command:

pip install pypop7

For Chinese users, sometimes the following PyPI configuration can be used to speedup the installation process of pypop7 owing to network blocking:

pip config set global.index-url https://mirrors.aliyun.com/pypi/simple/
pip config set install.trusted-host mirrors.aliyun.com

rather than the default PyPI setting:

pip config set global.index-url https://pypi.org/simple
pip config set install.trusted-host files.pythonhosted.org

If the latest cutting-edge version is preferred, you can install directly from the GitHub repository of pypop7:

git clone https://github.com/Evolutionary-Intelligence/pypop.git
cd pypop
pip install -e .

Conda-based Virtual Environment

You can first use the popular conda tool to create a virtual environment (e.g., named as env_pypop7):

conda deactivate  # close exiting virtual env
conda create -y --prefix env_pypop7  # free to change name of virtual env
conda activate ./env_pypop7  # on Windows OS
conda activate env_pypop7/  # on Linux
conda activate env_pypop7  # on MacOS
conda install -y --prefix env_pypop7 python=3.8.12  # create new virtual env
pip install pypop7
conda deactivate  # close current virtual env `env_pypop7`

Note that the above Python version (3.8.12) can be changed to meet your personal Python3 version (>=3.5 if possible).

Although we strongly recommend to use the the conda package manager to build the virtual environment as your working space, currently we do not add this library to conda-forge and leave it for the future (maybe 2024). As a result, you can only use pip install pypop7 for conda.

For MATLAB Users

For MATLAB users, MATLAB-to-Python Migration Guide or NumPy for MATLAB Users is highly recommended. Given the fact that the USA government blocks the MATLAB license to several universities, we argue that well-designed open-source software is really a good alternative like Python/NumPy (just to name a few).

For R Users

For R (and S-Plus) users, NumPy-for-R is highly recommended. Note that R is a free and well-established software environment for statistical computing and graphics.

Uninstalling this Open-Source Library

If necessary, you could uninstall this open-source library freely with one shell command:

pip uninstall -y pypop7