how to make virtualenv python code example Example 1: venv python -m venv c:\path\to\myenv Example 2: virtual environment python source env/bin/activate