Using Python Virtual Environment in DIAdem

Updated Dec 23, 2025

Reported In

Software

  • DIAdem 2025 Q2
  • DIAdem 2025 Q4

Issue Details

Does NI DIAdem support Python virtual environments (e.g., venv or virtualenv), and are there instructions or best practices for implementing a Python venv within DIAdem?

Solution

NI DIAdem & Python Support:

 

Starting with NI DIAdem 2025Q2, python virtual environments created with venv (and certain versions of virtualenv) are officially supported

 

Instructions to use python virtual environment in DIAdem:

 

  • Create python virtual environemnt using windows command prompt:
    1. Make sure compatible version of python is installed (For ex: Python version 3.8 or higher)
    2. Right-click the Start charm and type cmd, right-click the Command Prompt tile and select Run as administrator 
    3. Navigate to the DIAdem installation of Python using cd C:\Program Files\NationalInstruments\Shared\Skyline\Python
    4. Run the following command to create a virtual environment (Eg: DIAdem_venv)
      python -m venv DIAdem_venv
    5. Activate the created virtual environment 
      DIAdem_venv\Scripts\activate
    6. Perform any necessary module install using pip (Eg: numpy, pandas, etc.,) in the python virtual environment
      pip install pywin32 numpy pandas

       

    7. Reference screenshot showing the virtual environment creation.

       




       

  • Linking the python virtual environment to NI DIAdem:
    1. Open NI DIAdem.
    2. Navigate to Settings >> DIAdem Settings >> Script.
    3. Select User-defined under Python Installation
    4. Navigate to the Python virtual environment directory where python.exe is located (e.g.,C:\ProgramFiles\NationalInstruments\Shared\Skyline\Python\DIAdem_venv\Scripts), copy the full path to python.exe, and paste it into DIAdem settings in the Path field.
    5. Restart DIAdem to use the Python virtual environment in scripting.