Implements jpg.py