Fixed bug with masking in imageSplit.py