check for pil import

fix for the tribler 1h idle run with systemtap in venv (pil not loaded)