GoogleCloudPlatform / GoogleCloudPlatform/training-data-analyst

"Classifying Images with a Linear Model" lab requires graphviz Debian package install before any GUI steps

Open
#2,429 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jupyter Notebook
Stars
8.6k
Forks
6.1k
Avg merge
4h 44m
Merged PRs (30d)
2

Description

The 10th code cell would display the linear NN model's graph.
`tf.keras.utils.plot_model(model, show_shapes=True, show_layer_names=False)`

![linear_nn_graphviz](https://github.com/GoogleCloudPlatform/training-data-analyst/assets/744949/57d7b266-09b3-462e-bb97-332cab7770bb)

That fails with
`('You must install pydot (`pip install pydot`) and install graphviz (see instructions at https://graphviz.gitlab.io/download/) ', 'for plot_model/model_to_dot to work.')`

However `!pip install pydot graphviz` reveals that those python packages are installed in the notebook's python venv. However the underlying jupyter notebook's VM doesn't have the `graphviz` Debian package installed.

Trying `sudo apt install graphviz` failed because the GUI had apt locked. So this step should be done possibly right after the repo cloning, or even before that.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.