# Easy fix for this issue import PIL from PIL import ImageFont font = ImageFont.load_default() visualkeras.layered_view(model, legend=True, font=font)