Is there a method or package that converts a graph (or adjacency matrix) into a SMILES string?
For instance, I know the atoms are [6 6 7 6 6 6 6 8] ([C C N C C C C O]), and the adjacency matrix is
[[ 0., 1., 0., 0., 0., 0., 0., 0.],
[ 1., 0., 2., 0., 0., 0., 0., 1.],
[ 0., 2., 0., 1., 0., 0., 0., 0.],
[ 0., 0., 1., 0., 1., 0., 0., 0.],
[ 0., 0., 0., 1., 0., 1., 0., 0.],
[ 0., 0., 0., 0., 1., 0., 1., 1.],
[ 0., 0., 0., 0., 0., 1., 0., 0.],
[ 0., 1., 0., 0., 0., 1., 0., 0.]]
I need some function to output 'CC1=NCCC(C)O1'.
It also works if some function can output the corresponding "mol" object. The RDkit software has a 'MolFromSmiles' function. I wonder if there is something like 'MolFromGraphs'.