Beta-code for python image processing