adjust mpl.py to use new changes