In this tutorial we will use virtualenv with 3ds Max.
The virtualenv tool allows us to configure different independent Python execution
environments on our machine, each having its own set of installed pip packages.
The complete documentation for virtualenv can be found here
The Python embedded with 3ds Max includes the virtualenv tool, and we will be using that. Open a command prompt in the 3ds Max Python directory (typically something like C:\Program Files\Autodesk\3ds Max 202X\Python37) and create a virtual environment:
python -m virtualenv d:\myenvThen activate it by running:
d:\myenv\Scripts\activateStart 3ds Max:
3dsmaxs -python3From this moment we can use pip to add packages inside the virtual environment:
pip install somepackageAnd we are able to import the installed package in 3ds Max:
import somepackgage