def _validate_jp2_colr(self, boxes):
lst = [box for box in boxes if box.box_id == '<STR_LIT>']<EOL>jp2h = lst[<NUM_LIT:0>]<EOL>for colr in [box for box in jp2h.box if box.box_id == '<STR_LIT>']:<EOL><INDENT>if colr.approximation != <NUM_LIT:0>:<EOL><INDENT>msg = ("<STR_LIT>"<EOL>"<STR_LIT>")<EOL>raise IOError(msg)<EOL><DEDENT><DEDENT>
Validate JP2 requirements on colour specification boxes.