Completely rewrote flattenBrick() to use mc.calc on a pixel basis rather than iterative masking in a for loop. Works much faster now, and has multicore support.
Merge branch 'feature-flattenBrick' into develop