JP2 (JPEG 2000 Part 1) validator and properties extractor. Jpylyzer was specifically created to check that a JP2 file really conforms to the format's specifications. Additionally jpylyzer is able to extract technical characteristics.
CPFnum shall be equal to the value found in bits 0 to 11 of Rsiz of the corresponding codestream, unless that value is
4095, in which case CPFnum shall be equal to the PRFnum value found in the PRF marker segment of the corresponding
codestream.
This actually describes transfer between CPFNum and Rsiz values between Part 15 and Part 1 codestream during transcode. The standard text doesn't state this explicitly, but it does follow from the intended use cases for CPF:
Reversible transcode of an input Part 15 codestream to an output Part 1 codestream
Reversible transcode of an input Part 1 codestream to an output Part 15 codestream
For use case 1, Clause A.6 simply states that bits 0-11 of Rsiz in the output Part 1 codestream are set to the CPFNum value of the input Part 15 codestream.
Likewise, for use case 2 it states that the CPFNum value of the output Part 15 codestream is set according to bits 0-11 of Rsiz in the input Part 1 codestream.
This most likely also affects test CPFnumConsistentWithPRFnum, since it is currently dependent on the Rsiz value in the same codestream. Needs a more in-depth look, but on the surface I think this test should also be removed.
Clause A.6, Part 15:
This actually describes transfer between CPFNum and Rsiz values between Part 15 and Part 1 codestream during transcode. The standard text doesn't state this explicitly, but it does follow from the intended use cases for CPF:
For use case 1, Clause A.6 simply states that bits 0-11 of Rsiz in the output Part 1 codestream are set to the CPFNum value of the input Part 15 codestream.
Likewise, for use case 2 it states that the CPFNum value of the output Part 15 codestream is set according to bits 0-11 of Rsiz in the input Part 1 codestream.
This most likely also affects test CPFnumConsistentWithPRFnum, since it is currently dependent on the Rsiz value in the same codestream. Needs a more in-depth look, but on the surface I think this test should also be removed.