16 Commits

Author SHA1 Message Date
Ricardo Rodriguez
a44cbe8699 Fixes #7685 (#7864)
* replace lists with vectors

* remove redundant assign loop
2024-09-29 05:23:24 +02:00
Paolo Tosco
a384878fbe avoid leaking memory in case exceptions are thrown while generating FPs (#6630)
Co-authored-by: ptosco <paolo.tosco@novartis.com>
2023-08-15 04:59:14 +02:00
Eisuke Kawashima
27f711a658 Run clang-tidy (readability-braces-around-statements) (#4977)
https://github.com/rdkit/rdkit/pull/3024#discussion_r526549843
2022-03-10 08:00:10 +01:00
Ric
2c7485fef5 Fixes #4558 (#4559)
* fix

* add test
2021-09-25 15:45:30 +02:00
Eisuke Kawashima
78aac3c1bc Run clang-format against header files (#4143) 2021-06-08 07:57:51 +02:00
Greg Landrum
45b9aef28b clang-tidy modernize-use-default-member-init and modernize-use-emplace (#3190)
* run clang-tidy with modernize-use-default-member-init

* results from modernize-use-emplace

* one uniform initialization per line
otherwise SWIG is unhappy

Co-authored-by: Brian Kelley <fustigator@gmail.com>
2020-05-28 09:07:58 +02:00
Eisuke Kawashima
e86e2c1d5d Modernization: use nullptr (#3143) 2020-05-25 09:40:01 +02:00
Greg Landrum
ec366c1ab7 Dev/pvs studio cleanups2 (#2877)
* a round of cleanups courtesy of PVS studio

* add a test to make sure that a warning is a false alarm

* bug fix

* Fix a UFF bug

* more PVS studio cleanups

* next round of PVS studio cleanups

* completely remove the chances for that bug

* changes in response to review

* add an additional test
+ a bit of reformatting that snuck in
2020-01-22 15:10:58 +01:00
Greg Landrum
ff5266f40f Fix windows substructure crash (#2836)
* Fix a substructure crash on Windows

* re-enable some tests
2019-12-10 11:31:06 -05:00
John Mayfield
76ed536c87 Branch/vf2 optimisations (#2500)
* Remove out_1 and out_2, only need for directed graphs.

* Variable renaming, no other changes.

* Fix a couple things that were forgotten during the rename

* Only one of these counts is updated now.

* Add ifdef to enable/disable VF2Pruning

* Add degree bound check, could be pushed down to the generic VertexCheck predicate.

* The stack knows at each point what was added, by passing these into the Backtrack call the clone allocation can be removed.

* Indent and rename added_node1 to node1.

* Now the clone is removed we can add a member function to handle the recursion cleanly.

* Also make for MatchAll a member function.

* Set lim=0 to mean infinity.

* VF2Plus optimisation, when candidate is in the terminal set select from a mapped neighbours adjacency list.

* Optimisation hint.

* Use a struct for the Pair removing the need for double pointer and heap alloc/delete of the iterators.

* disable pruning by default (it's a bit quicker to not do this)

* update expected test results

The updated VF2 code can return symmetric results in a different order
than we were getting previously. The results are still correct, but they
change some of the downstream things that don't do symmetrization

* update expected java results
2019-06-30 04:49:24 +02:00
Greg Landrum
4b8caf2ceb Fixes #409 2015-01-10 07:21:55 +01:00
Greg Landrum
126e75a8b3 comment out the new substruct atom-match caching code; it does not seem to actually make things faster 2013-04-27 03:04:12 +00:00
Greg Landrum
c00d323eee set props 2013-03-28 10:30:40 +00:00
Greg Landrum
d79491aaf9 use caching of vertex matches to speed up the VF2 searches 2013-03-28 10:28:13 +00:00
Greg Landrum
414b579b1c first pass at support for supporting atomic stereochemistry in substructure matches 2013-03-10 07:33:00 +00:00
Greg Landrum
17fa9210e6 merge revs1065:1087 from vf2 branch into trunk 2009-04-18 18:25:27 +00:00