def test_null_conv_mol(self): """Running Null AggrMol Test. Only works when max_deg=6 and min_deg=0""" num_feat = 4 null_mol = ConvMol.get_null_mol(num_feat) deg_adj_lists = null_mol.get_deg_adjacency_lists() # Check that atoms are only connected to themselves. assert np.array_equal(deg_adj_lists[10], [[10, 10, 10, 10, 10, 10, 10, 10, 10, 10]]) assert np.array_equal(deg_adj_lists[1], [[1]]) # Check that there's one atom of each degree. assert np.array_equal(null_mol.get_deg_slice(), [[0, 1], [1, 1], [2, 1], [3, 1], [4, 1], [5, 1], [6, 1], [7, 1], [8, 1], [9, 1], [10, 1]])
def test_null_conv_mol(self): """Running Null AggrMol Test. Only works when max_deg=6 and min_deg=0""" num_feat = 4 min_deg = 0 null_mol = ConvMol.get_null_mol(num_feat) deg_adj_lists = null_mol.get_deg_adjacency_lists() # Check that atoms are only connected to themselves. assert np.array_equal(deg_adj_lists[10], [[10, 10, 10, 10, 10, 10, 10, 10, 10, 10]]) assert np.array_equal(deg_adj_lists[1], [[1]]) # Check that there's one atom of each degree. assert np.array_equal(null_mol.get_deg_slice(), [[0, 1], [1, 1], [2, 1], [3, 1], [4, 1], [5, 1], [6, 1], [7, 1], [8, 1], [9, 1], [10, 1]])