Script to check consistency of CTM file