File size: 317 Bytes
afb1ac5
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
# An utility repo to load conveniently fonts using hf_hub_download:

```python
from huggingface_hub import hf_hub_download
from PIL import ImageFont

font_path = hf_hub_download("jonathang/fonts-ttf", "Vogue.ttf")
font_obj = ImageFont(font_path, encoding="UTF-8")
```

(based on https://huggingface.co/ybelkada/fonts)