models icon indicating copy to clipboard operation
models copied to clipboard

visualization_utils.py change font size but still does not work.

Open cindysillence opened this issue 9 years ago • 3 comments

hallo I just run the object_detection_tutorial.ipynb script , but the text in the bounding box is too small and not clear. So I go to **/visualization_utils.py ** script to change the font size to "font = ImageFont.truetype('arial.ttf', 24)" but it still does not work.

how can I do it right now?

waiting for help

cindy chen

cindysillence avatar Nov 29 '17 12:11 cindysillence

This question is better asked on StackOverflow since it is not a bug or feature request. There is also a larger community that reads questions there. Thanks!

tatatodd avatar Nov 30 '17 01:11 tatatodd

This is a bug. ImageFont.truetype('arial.ttf', 24) fails because arial.ttf does not exist in the repo throwing a IOError: cannot open resource exception. As a result, ImageFont.load_default() is called every time.

@cindysillence you could just drop a copy of arial.ttf from your system folder in the ./research directory. This should cause ImageFont.truetype() to load arial.ttf correctly and then successfully set the font size.

ifnull avatar Aug 14 '18 04:08 ifnull

I have tried copying arial.ttf and changing the size in visualization_utils.py but still don't see a change. This is in Windows 10. Any suggestions?

dburns7 avatar Oct 07 '18 23:10 dburns7