def check_ExpCM_attributes(self):
self.assertEqual(self.nsites, self.expcm.nsites)<EOL>self.assertFalse(scipy.isnan(self.expcm.Prxy).any())<EOL>self.assertFalse(scipy.isinf(self.expcm.Prxy).any())<EOL>diag = scipy.eye(N_CODON, dtype='<STR_LIT:bool>')<EOL>for r in range(self.nsites):<EOL><INDENT>self.assertTrue(scipy.allclose(<NUM_LIT:0>, scipy.sum(self.expcm.Prxy[r],<EOL>axis=<NUM_LIT:1>)))<EOL>self.assertTrue(scipy.allclose(<NUM_LIT:0>, self.expcm.Prxy[r].sum()))<EOL>self.assertTrue((self.expcm.Prxy[r][diag] <= <NUM_LIT:0>).all())<EOL>self.assertTrue((self.expcm.Prxy[r][~diag] >= <NUM_LIT:0>).all())<EOL><DEDENT>self.assertTrue((self.expcm.prx >= <NUM_LIT:0>).all())<EOL>for r in range(self.nsites):<EOL><INDENT>self.assertTrue(scipy.allclose(<NUM_LIT:1>, self.expcm.prx[r].sum()))<EOL><DEDENT>for r in range(self.nsites):<EOL><INDENT>self.assertTrue(scipy.allclose(<NUM_LIT:0>, scipy.dot(self.expcm.prx[r],<EOL>self.expcm.Prxy[r])))<EOL>if r > <NUM_LIT:0>:<EOL><INDENT>self.assertFalse(scipy.allclose(<NUM_LIT:0>, scipy.dot(self.expcm.prx[r],<EOL>self.expcm.Prxy[r - <NUM_LIT:1>])))<EOL><DEDENT><DEDENT>
Make sure `ExpCM` has the expected attribute values.