Commit Graph

11 Commits

Author SHA1 Message Date
Greg Landrum
7f73da78a2 Fixes #4809: double bond stereo can now be set after calling replaceCore() (#4827)
* add test

* backup commit

* Fixes #4809

* cleanup

* don't make that change in large rings

* docs
2021-12-29 09:03:09 +01:00
Eisuke Kawashima
11532089de Run clang-format against cpp (#4358) 2021-10-20 04:25:27 +02:00
Greg Landrum
3a82159b57 Cleanup some problems found during an ASAN build (#4054)
* MolFragmenter: fix a leak when exceptions are thrown

* DistGeomHelpers: fix leaks when exceptions are thrown

* SubstructLibrary: fix usage of invalid memory

* clear up leaks found during ASAN testing
2021-04-21 10:22:04 -04:00
Brian Kelley
cf9ea71384 First pass at MolZip (now with bond stereo!) (#3644)
* First pass at MolZip (sans bond stereo)

* Add support for bond stereo zipping

* Add molzip swig wrappers

* Add simple python wrapper/tests

* Remove smiles round tripping now that fragmentOnBonds is fixed

* Responses to review

* AtomMaps and Isotopes must explicitly be set

* Add molzip single molecule api isotope test

* Add missing %newobject

* Add better python docs, label test

* fix docs add a test for molzip

* Update Code/GraphMol/ChemTransforms/MolFragmenter.cpp

Co-authored-by: Greg Landrum <greg.landrum@gmail.com>

* Add missing case breaks

* Add more preconditions, move mark and restore to private functions

* Remove unused and redunddant code

* optimize get_other_atom

* Add single arg molzip test

* Update Code/GraphMol/Wrap/rough_test.py

Co-authored-by: Greg Landrum <greg.landrum@gmail.com>

Co-authored-by: Greg Landrum <greg.landrum@gmail.com>
2020-12-25 05:15:12 +01:00
Brian Kelley
81481d5c6d BondStereo info lost in FragmentOnBonds() (#3649)
* Fix bondstereo when fragmenting molecules with cis/trans E/Z

* Apply suggestions from code review

Co-authored-by: Greg Landrum <greg.landrum@gmail.com>

* Add more tests for bond stereo

* Add test to ensure non-stereo atom bond breaks are preserved

* Remove extraneous test, fix another

Co-authored-by: Greg Landrum <greg.landrum@gmail.com>
2020-12-18 13:13:47 +01:00
Brian Kelley
66fa3c3a86 Reverts acciental molzip push 2020-12-08 17:04:07 -05:00
Brian Kelley
52bf58e254 Response to review: invert a and b molecules in tests. Fix bug found. 2020-12-08 10:23:53 -05:00
Brian Kelley
23ad0f8b84 Addd fragment on bonds and isotope labelling 2020-11-22 19:39:43 -05:00
Brian Kelley
847426faa2 Final algorithm implementation 2020-11-21 17:08:28 -05:00
Brian Kelley
08e0c714d7 First pass at molzip 2020-11-16 14:55:30 -05:00
Greg Landrum
ea0e8f674e Preserve bond direction in fragmentOnBonds (#2484)
* Sketch of a solution to preserve bond direction in fragmentOnBonds

* A bit of cleanup work based on Andrew's original commit for #1039
Add a couple of tests too

* forgot to save a file before the commit
2019-06-10 13:08:50 -04:00