Skip to content

Instantly share code, notes, and snippets.

@IngIeoAndSpare
Created April 15, 2021 05:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save IngIeoAndSpare/4fb52fcd8143dbc6a82a2826124a417a to your computer and use it in GitHub Desktop.
Save IngIeoAndSpare/4fb52fcd8143dbc6a82a2826124a417a to your computer and use it in GitHub Desktop.
colab 한글깨짐 방지
import matplotlib.pyplot as plt
import matplotlib as mpl
import matplotlib.font_manager as fm
%matplotlib inline
%config InlineBackend.figure_format = 'retina'
!apt -qq -y install fonts-nanum
fontpath = '/usr/share/fonts/truetype/nanum/NanumBarunGothic.ttf'
font = fm.FontProperties(fname=fontpath, size=10)
plt.rc('font', family='NanumBarunGothic')
mpl.font_manager._rebuild()
mpl.rcParams['axes.unicode_minus'] = False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment