You need to have specific permissions to create, modify and use code environments. If you do not have these permissions, contact your DSS administrator.
Create a code environment¶
- Go to Administration > Code envs
- Click on “New Python env”
- Give an identifier to your code environment. Only use A-Z, a-z, digits and hyphens
Code environment identifiers must be globally unique to the DSS instance, so use a complete and descriptive identifier
- Choose the Python version that you want to use. DSS is compatible with Python versions 2.7, 3.4, 3.5 and 3.6.
- The requested version of Python must be installed on your system (by your system administrator)
- In most cases, you also need the Python development headers packages in order to install packages with pip. Depending on the OS, this system package (to be installed by the system administrator) is called “libpython-dev” or “python-devel”
- Click on create
- DSS creates the code environment and installs the minimal set of packages
If you plan to use Visual Machine Learning with this code environment, it must include the scipy, scikit-learn, jinja2 and xgboost packages.
- You are taken to the new environment page
You can manage the list of packages to install by clicking on the “Packages to install” tab.
You see here two lists:
- A non-editable list of the “base packages”. These are packages that are required by your current settings. These packages cannot be removed, and you cannot modify their version. For more information, see Base packages
- An editable list of “Requested packages”. This is where you write the list of packages that you want in your virtual environment.
The list of requested packages is in the
requirements.txt file format See the documentation about the format of requirements.txt. Each line must be a package name, optionally with constraints information.
Once you have written the packages you want, click on Save and update. DSS downloads and installs the newly required packages
Afterwards, you can inspect the exact installed versions in the “Actually installed packages” tab.
Installing packages not available through pip¶
Unfortunately some packages are not available on pip, and usually installing the package requires to run the python setup.py install command.
TODO: Explain that admin first downloads them and then how to put that in requirements.txt