phi-grib / flame

Modeling framework for eTRANSAFE project
GNU General Public License v3.0
12 stars 10 forks source link

errors importing syntactically uncorrect SDFiles #167

Closed manuelpastor closed 4 years ago

manuelpastor commented 4 years ago

When an SDFile contains an empty molecule it generates import problems

1-mixed.zip

manuelpastor commented 4 years ago

When the empty molecule looks like this:

EMPTY MOL

0 0 0 0 0 0 0 0 0 0999 V2000 M END $$$$

RDKit supplier has a non-deterministic behaviour. If supplier len has been checked, the SDFile is split correctly but if len has not been called, the supplier merges the empty molecule with the next one

manuelpastor commented 4 years ago

It was fixed in idata, but also in sdfileutils (by forcing the len call in count_mols) and in md_computation by checking if the mols has a zero heavy atoms count