Commit 6005f793 authored by Daniele Venzano's avatar Daniele Venzano

Force rebuild with new base images

parent 4ba27d51
Pipeline #10398 passed with stages
in 18 minutes and 54 seconds
......@@ -5,7 +5,7 @@ stages:
- deploy
variables:
VERSION: 10366
VERSION: 10396
REPOSITORY: zapps
before_script:
......
......@@ -8,3 +8,34 @@ This ZApp contains a Jupyter Notebook with a Python 3.5 kernel and the following
The GPU version contains also CUDA 9.0 and tensorflow with GPU support
## Customizations
### Adding Python libraries
To install additional libraries you can add the following code on top of your notebook:
import subprocess
import sys
def install(package):
subprocess.call([sys.executable, "-m", "pip", "install", package])
and call the `install(<package name>)` function to install all packages you need.
### Running your own script
By modifying the `command` parameter in the JSON file you can tell Zoe to run your own script instead of the notebook.
In this ZApp the default command is:
"command": "jupyter lab --no-browser --NotebookApp.token='' --allow-root --ip=0.0.0.0"
If you change the JSON and write:
"command": "/mnt/workspace/myscript.sh"
Zoe will run myscript.sh instead of running the Jupyter notebook. In this way you can:
* transform an interactive notebook ZApp into a batch one, with exactly the same libraries and environment
* perform additional setup before starting the notebook. In this case you will have to add the jupyter lab command defined above at the end of your script.
......@@ -36,3 +36,7 @@ RUN pip install --upgrade pip \
torch==0.4.1 \
torchvision
# nvidia-docker
LABEL com.nvidia.volumes.needed="nvidia_driver"
LABEL com.nvidia.cuda.version="${CUDA_VERSION}"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment