From 01a1593441cc20b3c0c59326b0b32331a9e7f57a Mon Sep 17 00:00:00 2001 From: Hilmar Lapp Date: Wed, 27 Nov 2024 00:16:16 -0500 Subject: [PATCH] Adds pydot and graphviz for plotting model layer graphs --- Dockerfile-pyonly | 9 ++++++++- common-requirements.txt | 2 ++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/Dockerfile-pyonly b/Dockerfile-pyonly index 7ccf5a9..b92ec89 100644 --- a/Dockerfile-pyonly +++ b/Dockerfile-pyonly @@ -62,7 +62,14 @@ RUN [[ -n ${CUDA} ]] && \ fix-permissions "${CONDA_DIR}" && \ fix-permissions "/home/${NB_USER}" -# Additional packages we may need +# Install graphviz for pydot, which is needed by keras.util.plot_model +RUN mamba install --yes \ + 'graphviz' && \ + mamba clean --all -f -y && \ + fix-permissions "${CONDA_DIR}" && \ + fix-permissions "/home/${NB_USER}" + + # Additional packages we may need COPY common-requirements.txt requirements.tf-${TENSORFLOW_VERSION}.txt /tmp/ RUN pip install --no-cache-dir \ tensorflow==${TENSORFLOW_VERSION} \ diff --git a/common-requirements.txt b/common-requirements.txt index 2d37db4..46b58dd 100644 --- a/common-requirements.txt +++ b/common-requirements.txt @@ -20,3 +20,5 @@ oaklib matplotlib<3.9.0 seaborn coolbox +# pydot will need graphviz as dependency +pydot