python resouce code