10 Commits

Author SHA1 Message Date
Greg Landrum
15751b3651 Add multi-threaded versions of some MolStandardize operations (#6909)
* initial addition of MT support to MolStandardize

* do the other inplace functions

* add mt ops to python wrappers
including tests

* release the GIL

* remove exploratory code added during dev

* make normalizer thread safe

* refactor some repeated code
2023-11-24 18:36:17 -05:00
Gareth Jones
c2fb57c19f RGD - a fix for the cubane issue (single target atom matches 2 user R group attachments) (#4002)
* Most tests working

* All tests working

* Fixed tests after merge with master

* Create header and implementations for RCore

* Updated comments

* Removed old code

* DLL export for MolMatchFinalCheckFunctor

* Information line for failing Mac test

* Log replace core behaviour

* Ordering fix for OSX

* Possible fuzzer fix

* Removed debug output

* Fix unmatched user R group bug

* Code review changes

* Bug fix and ChemTransforms test
2021-05-23 15:16:03 -04:00
Gareth Jones
81d3705358 R group match any issue (#3767)
* RGD modifications for any atom and index labels

* Continued development

* All tests working

* Added comment

* CR changes suggested by PTosco

* Fix catch_rgd for autocrlf

* Core dummy matches on output. RGroups on heavy atom. Dummy atoms User rgroups only when they are degree 1.

* Start work on test fixes

* testRGroupDecomp test working

* CPP and Python tests working

* Removed options for matching core query atoms on sidechains

* Windows build fix

* R groups off ring. User group matches single heavy substituent. Remove extraneous hydrogens

* Updated fingerprint variance score and tie selection

* Refactor fingerprint variance score functions to class

* Removed fingerprint distance score

* Boost::trim fix

* Updated RGD test notebook

* Fixed AddHs.cpp

* - fixes the kekulization issue
- avoids that empty R-group labels are included in cores
- makes sure that SMILES cores are always canonical
- adds a few missing const declarations and avoids unintentional copying

* Support for allowNonTerminalRGroups parameter. Remove R groups that contain H or Nothing.  Ignore R group labels on non-dummy atoms

* Fixed tests for Paolo's changes. Rebuilt test notebook.  Increased weighting of rgroup penalty in fingerprint variance score

* remove some debug output

Co-authored-by: Brian Kelley <fustigator@gmail.com>
Co-authored-by: greg landrum <greg.landrum@gmail.com>
2021-03-10 12:56:42 +01:00
Gareth Jones
ec5a172886 R group symmetry (#3565)
* Exploration

* Initial work on GA fro Rgroup Symmetry

* GA for rgroup decomp and fingerprint rgroup symmetry scoring

* Continuing development

* Exploration

* Initial work on GA fro Rgroup Symmetry

* GA for rgroup decomp and fingerprint rgroup symmetry scoring

* Continuing development

* Further development

* Continued tweaks

* Function rename

* Continued tweaks

* Bug fix for variance calculation

* Copyright notices. Remove Eigen dependency. RdKit logging.  Clock fix.

* Changes to fix build failures

* Fixes for Windows dynamic DLL build

* Included GA export.h file

* Fixed RGroupDecomp CMakeLists.txt

* Notebooks working, GGroup labelling bug fixed

* Fix windows build.  More options for example GA program

* More bugs found and tests adjusted

* Fixed Python rgroup test

* Trivial change to trigger CI

* OSX java and windows build fixes

* Windows DLL fix

* Fix segmentation error

* proposed change

* Possible fix for segmentation fault

* CR fixes

* CR fixes

* CR fixes

* Recreates molecules from rgroups where possible

Co-authored-by: greg landrum <greg.landrum@gmail.com>
Co-authored-by: Brian Kelley <fustigator@gmail.com>
2021-01-05 09:27:33 -05:00
Eisuke Kawashima
5cd27a242f Fix typo (#2862)
* Fix typo

* Reflect the comments

* Fix more typos
2019-12-31 06:43:27 +01:00
Greg Landrum
70861d5b11 update fingerprint tutorial notebook (#2130) 2018-10-26 13:09:20 +02:00
Greg Landrum
8b115b22c5 Move MolStandardize Tutorial to Docs/Notebooks 2018-10-18 05:33:13 +02:00
Boran Adas
139d2bdb83 GSoC 2018 - Fingerprints (#2005)
* Fingerprint generator first prototype

* Added some more details to the prototype

* Update based on comments

* Added additional outputs and return type changes

* FingerprintGenerator updated and placeholder implementation added

* Added getFingerprint implementation to FingerprintGenerator

* Added comments for FingerprintGenerator

* WIP: Atom pairs fingerprint implementation for FingerprintGenerator

* Removed templates and added comments

* Fixed AtomPairEnvGenerator creating duplicate environments

* Added a atom pair old version compatibility test

* Moved the FingerprintGenerator related tests to a new file

* Added new comments and changes from the PR comments

* using int types from std instead of boost and remove cleanUpEnvironments

* Minor refactoring for atom-pair atom code generation

* Added more tests for AtomPairGenerator

* Removed additional clean up method from FingerprinGenerator

* Added additional output for atom-pair fingerprint and a test

* Removed leftover code

* Default argument changes

* Removed leftover include

* Default invariant generation logic seperated from env generation logic for AtomPairs

* Implemented fingerprint as bit vector type and added the test for it

* Folded fingerprint implementation and a test case added

* String representation for fingerprint generator is added

* Python wrapper for fingeprint generator added with a simple test

* Removed unused linked libraries

* AtomPair related wrapper code moved to its own file

* Python wrapper methods for different fingerprint output types added

* Wrappers for invariants generators and tests are added

* Added more comments and tests

* Changed python side names for FIngerprintGenerator and removed extra wrappers used for invariant generators on python

* Fixed object lifetime problems for invariant generators in  Python

* Fixed typo

* Added a list of test molecules and made fingerprint generator related classes noncopyable

* Morgan fingerprint python wrappers

* Removed argument helper class for wrapper

* Morgan Fingerprint simple implementation

* Added more invariants generators for Morgan

* Fixed a bug in Morgan bond invariant generator

* Added invariant generator combination tests

* Added atom pair generator to the invariant generator combination test

* Fixed a problem in morgan feature invariant generator

* Overriding invariants without generators is made possible

* Added comments and documentation

* Radius changed for morgan fingerprint test

* RDKit fingerprint generator implementation with cpp tests

* 32 bit and 64 bit fingerprint support for FingerprintGenerator

* Common utilities moved to FingerprintUtil.h and code duplication reduced

* Solved undefined reference issues for FPGenerator templates

* Topological torsion fp generator added

* Fingerprint notebook added

* Python wrappers updated

* Morgan tests added

* Tests expanded and reduced excess amounts of collision in folded output

* Expanded tests

* More documentation

* Python docs for atom pair

* Updated fingerprint generator notebook

* Python wrapper documentation added

* Seperated FingerprintGenerator implementations into seperated file again

* Python wrapper names updated to reflect new naming

* getCountFingerprint now returns 32 bit output and count simulation does not affect count fingerprints

* Python 3 compatibility for fingerprint generator tests

* a bit of ABC cleanup

* some comment formatting got screwed up

* <sigh>

* fix an uninitialized memory problem

* Added copyright statement to new files

* Corrected some comments and docs according to the latest changes

* Bulk fingerprint generation and tests

* Convenience function wrappers and size limiting for getSparseFingerprint

* Copyright text fixed

* Info string added to python wrappers

* Some changes to get the swig wrappers building again
2018-10-07 05:02:12 +02:00
Brian Kelley
9cebcaf48a Makes notebooks smaller.\n\tAt some point the old versions should be purged from history (#1520) 2017-08-11 15:44:22 +02:00
Greg Landrum
62150f7d80 Squashed commit of the following:
commit 7f7b5268a62eecd260027e0918abbdf62b100034
Merge: 90e9fd3 6dd173d
Author: Greg Landrum <greg.landrum@gmail.com>
Date:   Tue Aug 8 01:19:15 2017 +0200

    merge back to master

commit 6dd173dec6
Merge: 45a94bd e11ad49
Author: Brian Kelley <fustigator@gmail.com>
Date:   Thu Aug 3 07:54:26 2017 -0400

    Merge pull request #8 from greglandrum/dev/rgroup-decomposition

    support using generic iterators in ctor;

commit e11ad49068
Author: Greg Landrum <greg.landrum@gmail.com>
Date:   Tue Aug 1 06:29:52 2017 +0200

    move notebooks to docs

commit 606c03c28f
Author: Greg Landrum <greg.landrum@gmail.com>
Date:   Thu Jul 27 05:13:13 2017 +0200

    support using generic iterators in ctor;
    general comment: this is a useful pattern that we could use elsewhere

commit 45a94bd663
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Wed Jul 26 13:30:23 2017 -0400

    Updates notebooks

commit 8f78ba97d3
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Wed Jul 26 09:00:42 2017 -0400

    Updates notebooks

commit 44728803ae
Merge: d67409d 4d0b00d
Author: Brian Kelley <fustigator@gmail.com>
Date:   Wed Jul 26 08:53:11 2017 -0400

    Merge pull request #7 from greglandrum/dev/rgroup-decomposition

    clean up a couple leaks and some compiler warnings

commit 4d0b00dd2e
Author: Greg Landrum <greg.landrum@gmail.com>
Date:   Wed Jul 26 07:47:56 2017 +0200

    clean up a couple leaks and some compiler warnings

commit d67409da0c
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Tue Jul 25 11:43:14 2017 -0400

    Makes the scoring system more sane

commit 1b5181dc2f
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Tue Jul 25 10:55:33 2017 -0400

    Finalizes enums

commit 7e9ee61556
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Tue Jul 25 10:55:18 2017 -0400

    Fixes constructor botched in the last commit

commit aed2a201bf
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 24 18:22:42 2017 -0400

    Cleans up some code

commit 95e82a1398
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 24 18:14:31 2017 -0400

    Removes unused variable

commit 0b1ed09316
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 24 18:14:23 2017 -0400

    Slight optimization by combining two loops

commit ed3340a516
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 24 13:53:06 2017 -0400

    Fixes post increments in for loops

commit 25b1678a58
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 24 13:52:53 2017 -0400

    Fixes memory leak and doesn’t call SmartsToMol twice

commit 86c8c42688
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 24 13:52:32 2017 -0400

    Adds header guards

commit b043e38d3a
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 24 13:52:25 2017 -0400

    Removes unused variable

commit 631aa77153
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Tue Jul 11 08:10:39 2017 -0400

    Fixes typo in filename

commit d6e0dc753a
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 10 14:48:04 2017 -0400

    Fixes c++11 style enums

commit b9a31eae9a
Author: Brian Kelley <brian.kelley@novartis.com>
Date:   Mon Jul 10 14:00:04 2017 -0400

    Adds RGroupDecomposition attempt
2017-08-08 01:23:49 +02:00