Skip to content

Commit

Permalink
[WB-4663] Added Matplotlib guard (#1890)
Browse files Browse the repository at this point in the history
  • Loading branch information
tssweeney authored Feb 26, 2021
1 parent eba2919 commit 181fc47
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion wandb/integration/fastai/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@
try:
import matplotlib

matplotlib.use("Agg") # non-interactive backend (avoid tkinter issues)
if wandb.wandb_lib.ipython._get_python_type() != "jupyter":
matplotlib.use("Agg") # non-interactive backend (avoid tkinter issues)
import matplotlib.pyplot as plt
except:
print("Warning: matplotlib required if logging sample image predictions")
Expand Down

0 comments on commit 181fc47

Please sign in to comment.