@classmethod<EOL><INDENT>def setUpClass(cls):<DEDENT>
j2k = Jp2k(glymur.data.goodstuff())<EOL>data = j2k[:]<EOL>with tempfile.NamedTemporaryFile(suffix="<STR_LIT>", delete=False) as tfile:<EOL><INDENT>Jp2k(tfile.name, data=data[:, :, <NUM_LIT:0>])<EOL>cls.one_plane = tfile.name<EOL><DEDENT>with tempfile.NamedTemporaryFile(suffix="<STR_LIT>", delete=False) as tfile:<EOL><INDENT>Jp2k(tfile.name, data=data[:, :, <NUM_LIT:0>:<NUM_LIT:1>])<EOL>cls.two_planes = tfile.name<EOL><DEDENT>with tempfile.NamedTemporaryFile(suffix="<STR_LIT>", delete=False) as tfile:<EOL><INDENT>shape = (data.shape[<NUM_LIT:0>], data.shape[<NUM_LIT:1>], <NUM_LIT:1>)<EOL>alpha = np.zeros((shape), dtype=data.dtype)<EOL>data4 = np.concatenate((data, alpha), axis=<NUM_LIT:2>)<EOL>Jp2k(tfile.name, data=data4)<EOL>cls.four_planes = tfile.name<EOL><DEDENT>
Need a one_plane plane image for greyscale testing.