Skip to content

Commit 790a36c

Browse files
Update script to produce only word cloud w/o reference image beside
1 parent c4b1e66 commit 790a36c

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

vis/definitions_wordcloud.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,11 @@ def generate_wordcloud(text):
6060
image_colors = ImageColorGenerator(alice_coloring)
6161

6262
# show
63-
fig, axes = plt.subplots(1, 2)
63+
fig, axes = plt.subplots(1, 1)
6464
# recolor wordcloud and show
6565
# we could also give color_func=image_colors directly in the constructor
66-
axes[0].imshow(wc.recolor(color_func=image_colors), interpolation="bilinear")
67-
axes[1].imshow(alice_coloring, cmap=plt.cm.gray, interpolation="bilinear")
68-
for ax in axes:
69-
ax.set_axis_off()
66+
axes.imshow(wc.recolor(color_func=image_colors), interpolation="bilinear")
67+
axes.set_axis_off()
7068
plt.show()
7169
fig.savefig("images/definitions_word_cloud.png")
7270

7.99 KB
Loading

0 commit comments

Comments
 (0)