Since the full quality, unstretched images became available for M20, the brightness matching became unnecessary for most Engineering Camera images.
For images with non-standard tiling structures, the algorithm also produces undesirable results, like here for FLF_0923_0748887303_658ECM_N0450000FHAZ00203

I temporarily disabled the color matching in the code and assembled the image again which yields this basically perfect result:

I recommend to make it the default behaviour that brightness matching is disabled. Maybe it can be re enabled when an additional flag is specified.