python 3 compatibility + add copyright