Commit Graph

2450 Commits

Author SHA1 Message Date
Greg Landrum
a633b63159 Fix for #1478 (#1486)
* Fixes #1478

* minor optimization
2017-07-07 05:53:31 +02:00
Brian Kelley
a74c4b3d12 Fixes lookup for HELM Monomer 'D' (#1477) 2017-07-07 05:53:08 +02:00
Greg Landrum
b412223d67 Fixes #1472 (#1473)
* Fixes #1472

* handle isotope info too
2017-07-07 05:52:40 +02:00
Brian Kelley
556b538a4b Fixes sanitizereaction throwing errors with unused rlabels in product template (#1451) 2017-07-07 05:50:51 +02:00
Matt Swain
9e3fbe2121 Fix cxsmiles parse on VS2008 (#1415)
* Fix cxsmiles parse on VS2008

* Fix other instances of dangerous iterator incrementing

* Fix for modern compilers
2017-07-07 05:48:51 +02:00
Greg Landrum
00d37905dd fixes #1435 (#1437) 2017-06-06 05:47:25 +02:00
Greg Landrum
3a557df24b modify pattern fp order; update expected psql results (#1399)
* move the new pattern to the end of the list so that existing bit definitions stay constant

* update expected results for psql tests
2017-04-19 11:57:48 -04:00
Greg Landrum
5f7e04fe5d Fix github1240 (#1396)
* add a test (currently fails, of course)

* backup, not really working

* Fixes #1240

* a bit more parameter tweaking to get some more structures to embed
2017-04-18 02:33:23 -04:00
Greg Landrum
e9eb89e4b1 Fix #1227 (#1393)
* Fixes #1227

* make only heavy atoms the default with the pre-defined param sets; this may not be the right answer
2017-04-09 10:20:41 -07:00
Greg Landrum
d3ad7d2770 Fixes #1387 (#1392)
* backup

* Fixes #1387
this passes the bug tests, but needs the full tests run

* all tests pass

* remove some droppings left from an earlier attempt at a fix

* remove some additional printing

* cleanup
2017-04-07 11:57:43 -04:00
Greg Landrum
f816f7fd12 Fixes #1388 (#1389) 2017-04-01 08:13:52 -04:00
David Cosgrove
fcc2e226ff Get started c++ (#1285)
* Start of GettingStartedInC++ documentation.

* Changed GettingStartedInC++ from rst to markdown format. Added some more text.

* Added Working with Molecules to GettingStartedInC++

* Expanded on behaviour of Kekulize wrt clearing aromatic flags on atoms and bonds.

* Added section Modifying Molecules.

* More plodding progress.

* A load more documentation.

* Undid change to global CMakeLists.txt

* Minor editing of docs.

* Changed examples so they use RDBASE to find test data rather than relative
path.

* Fixed use of -std=c++ in CMakeLists.txt. Extra waffling about memory.

* Modifications to examples and documentation as requested.

* Couple of minor changes.

* Change to example11.cpp and associated text in docs.
2017-03-30 04:50:53 +02:00
Greg Landrum
49bbd95532 Fixes #1385 (#1386) 2017-03-29 08:05:05 +02:00
Greg Landrum
d0ca6be205 Add feature for #1375 (#1384)
* documentation update

* Fixes #1375
2017-03-28 16:02:21 -04:00
Greg Landrum
283332e4de Fix/github1366 (#1382)
* add test

* update that test

* add python version of a test

* add some preconditions before dereferencing pointers

* make data members of AtomIterators private (not sure why these were ever made public)

* Fixes #1366

* switch to using std::runtime_error

* switch python tests too

* move the tests from the C++ side to be on the python side.
2017-03-28 16:01:36 -04:00
Greg Landrum
8c10f6a99e Revert "Fix/github1366 (#1374)" (#1381)
This reverts commit cecb51ef35.
2017-03-27 05:58:18 +02:00
Greg Landrum
cecb51ef35 Fix/github1366 (#1374)
* add test

* update that test

* add python version of a test

* add some preconditions before dereferencing pointers

* make data members of AtomIterators private (not sure why these were ever made public)

* Fixes #1366

* switch to using std::runtime_error

* switch python tests too
2017-03-26 22:11:09 -04:00
Brian Kelley
a02f2b0bb1 Fix/sanitizerxn merge hs (#1367)
* Fixes exceptions to use correct functionName

* Deprecates ChemDrawAdjustParams name sciquest integration/eln searching
 doesn’t map to this behavior.  renamed  MatchOnlyAtRgroupAdjustParams

* Python wrapper for deprecated API

* fixHs now is more intelligent about merging hs.

The only cases where hs can’t be merged is if they are mapped
to a non hydrogen in the product.

* Updates deprecated ChemDrawAdjustParams
2017-03-20 14:30:36 +00:00
Greg Landrum
59e6508d4f stop using getBondWithIdx() in removeBond() (#1363)
Fixes #1359
2017-03-12 10:07:17 -04:00
Greg Landrum
2a916b1a74 the functionality was already there, this just shows how to use it (#1355) 2017-03-12 09:57:43 -04:00
Greg Landrum
ffb1af7090 Fix handling of Hs in SMARTS queries (#1339)
* Fixes #1338;
cmake files still need to be updated

* all tests now pass

* a bit of reworking about how bare Hs are handled

* more perversity

* update cmake files for those changes

* test atom map too
2017-03-08 23:17:50 -05:00
Greg Landrum
09d7314aed Feat/github1325 (#1347)
* Fixes #1325

* add a smart PRECONDITION
2017-03-08 23:17:29 -05:00
Greg Landrum
103a84da4d Fix/github879 (#1354)
* Fixes #879

* add warning to release notes
2017-03-08 23:17:04 -05:00
Greg Landrum
fbeb88e341 Fixes #1352 (#1353) 2017-03-06 11:22:54 -05:00
Brian Kelley
45667974ca Small change to enum to prevent overflowing in boost when the compiler chooses int type (#1351) 2017-03-06 05:31:37 +01:00
Greg Landrum
e52cf5c666 Fix/github1286 (#1307)
* clean up the header a bit
clang-format

* clang-format

* add test for #1286

* backup

* fixes the specific failure, but needs more looking

* add an additional test

* update the inchi code to explicitly include queue

* fix a typo identified during the review
2017-03-04 12:35:26 -05:00
Greg Landrum
adad6e55c2 Fix two problems with the PDB parsing (#1341)
* Fixes #1029

* Fixes #1340

* add test files
2017-03-04 12:34:27 -05:00
Greg Landrum
527b6cd922 Fixes #1322 (#1342) 2017-03-04 12:33:34 -05:00
Greg Landrum
ddfb9e0dc5 Support parsing atom properties and atom values from cxsmiles (#1343)
* fix a possible infinite loop in cxsmiles parser

* support atom values from cxsmiles
this also adds proper handling of escaped characters in cxsmiles text

* add atom props
a bit of refactoring too
2017-03-04 12:30:01 -05:00
Greg Landrum
4001b2ba0e Add the option to match formal charges to FMCS (#1311)
* very basics of charge checking in

* add the new parameters to the python wrapper. more testing please

* Additional testing.

* update which unittest methods are used
2017-02-28 08:49:28 -05:00
Brian Kelley
ea8d7e68f9 Dev/rdmmpa api update (#1291)
* Adds FragmentMol with minCuts specified

* Adds ability to cut by bond indices as opposed to smarts patterns

* Fixed API (remove maxBondCuts when bonds are sent in)

* Adds bond api test

* Fixes docs

* Small doc change

* Removes cstdint

* Adds ValueError minor bond retrieval optimization

* Removes fragMolHelper4

* Tests ValueError

* py3 fix
2017-02-27 17:08:01 +01:00
Brian Kelley
287b3a1b36 Fix/rogers fixes (#1293)
* Fixes older apple/gcc builds spewing too many warning

* Fixes typo

* Removes  -Wno-unused-local-typedef from CMakeLists.txt
2017-02-27 16:28:12 +01:00
Greg Landrum
e625c58bab Add cis/trans tags to double bonds (#1316)
* add cis and trans to bond stereo

* compiles, does not work

* tests all pass

* Whitespace cleanup to recent changes.

* C++ test case for Bond::setStereo using Bond::STEREOCIS and Bond::STEREOTRANS

* Adding a PRECONDITION to Bond::setStereo to make sure the stereo atoms
are already specified if CIS or TRANS is being specified.

E/Z is technically defined by the topology of the molecule so the
stereo atoms are redundant (easier to understand and use!), but
ultimately redundant with the graph. However, CIS and TRANS is _only_
defined in this usage as the orientation of the atoms in the
getStereoAtoms vector.

* Exposing Bond::setStereo to Python and adding test cases to make sure
it can be used to set CIS/TRANS stereochemistry.

* verify substructure matching works

* Adding Bond::setStereoAtoms to C++ Bond class.

This allows setting the atoms to be considered for CIS or TRANS
directly without a much more costly determination of ranking that E/Z
requires.

* Wrap Bond::SetStereoAtoms into python with a new type of test case.

* docs
2017-02-26 08:15:44 -05:00
Greg Landrum
0eb42b4605 Resolve #1323 (#1327)
* works, but needs more testing

* progress

* at least a modicum of testing
2017-02-22 07:23:47 -05:00
Greg Landrum
f2c1a95c6e Fixes #1294 (#1302)
* Fixes #1294
There was no reason to require only two ring bonds.

* code now matches the docs
2017-02-10 08:50:28 -05:00
Greg Landrum
6152165ad3 Fix/github1287 (#1297)
* Fixes #1287

* unconnected fix to clean up a compiler warning from clang
2017-02-09 13:01:43 -05:00
Brian Kelley
e70599a12e Dev/pickle properties (#1277)
* Adds pickling of properties (optional)

* Ignores RDKit::Dict::Pairs - previously private

* Fixes AllProps definition

* Fixes BondProps seperation

* Fixes reaction pickling - Adds ability to pickle atom + QueryAtom

* Bumps pickle version

* Removes fugly post-increments

* Changes Default to NoProps

* Tests more options for pickling

* Runs clang format

* Adds get/setDefaultPropertyPickleOptions, exposes to python

* turns tests back on.

* Fixes enum (clang was allowing c++11 semantics)

* Adds global settings test

* Code/GraphMol/testPicklerGlobalSettings.cpp
2017-02-09 16:06:01 +01:00
Greg Landrum
270f7b76e5 Partial support for reading CXSMILES (#1237)
* add a SmilesParserParams object to prepare for this

* add a SmilesParserParams object to prepare for this

* add tests for the SmilesParseParmas

* support name parsing, should it be the default?

* rename CXNSmiles to CXSmiles;
add a spirit parser for CXSmiles coordinate that is at least syntax correct

* abandon boost::spirit for now; crude atom token parser

* support params in smiles parser (not tested, may not build)

* can read coords and atom labels along with mol names; crude, but works

* read coordinate bonds

* remove some compiler warnings with VS2015

* remove a bunch of compiler warnings on windows

* remove more warnings on windows

* remove more warnings on windows

* backup commit: first pass at parsing query features

* radical spec parsing

* handle attachment points using atom mapping

* switch to a named property for atom labels

* fix handling of the "A" atom query

* add functions to construct A and Q queries (needs more work)

* fix a problem created while cleaning up warnings earlier

* add some additional convenience functions for making generic atoms.
Still need M and to recognize these while writing CXSMILES

* add M queries; update some tests

* fix a linux compile problem

* get the cxsmiles stuff working in python; basic testing

* support "M" in CXSMILES
2017-01-31 13:50:36 -05:00
Greg Landrum
0eb715ed5e initial pass at dative directions (#1254) 2017-01-27 17:25:58 -05:00
Greg Landrum
f196567182 Fixes #1271 (#1272)
* Fixes #1271

* add a comment or two

* fix single-atom molecules too

* add a test for grid drawing too

* simplification of the special cases; no need to make things so complex
2017-01-22 13:49:09 -05:00
Greg Landrum
fb2c546948 Fix/github1262 (#1265)
* fix for calculation of prinicipal moments of inertia

* fix a typo
update expected values

* PMI and NPR tests working

* cleanup some of the other descriptors and tests

* Test against Moments.py descriptors

* add new tests from Brian

* remove some warnings
2017-01-22 05:49:52 +01:00
Greg Landrum
c775b0c04e Fixes #1266 (#1270) 2017-01-20 09:23:18 -05:00
eloyfelix
0519845b26 Add python wraps (#1259)
* added PeriodicTable GetMostCommonIsotope python wrap

* added PeriodicTable GetMostCommonIsotope python wrap

* added wraps for GetMostCommonIsotopeMass, GetAbundanceForIsotope, GetRb0 and all it's tests
2017-01-16 10:16:48 +01:00
Greg Landrum
7ee348feb3 Fixes #1251 (#1252) 2017-01-09 16:29:06 -05:00
Paolo Tosco
72066affe9 - Optimization of UFF and MMFF forcefields (#1218)
* - optimization to UFF and MMFF forcefields

* - further optimizations (memset, factoring unnecessary in-loop
  initialization out of the loop, replacing if clause with pre-increment)

* - fixed a couple of stylistic glitches

* - the torsionSmarts parameter in addTorsions() is now a const std::string&

* - implemented the DefaultTorsionBondSmarts singleton using boost::call_once()
2017-01-04 08:33:34 +01:00
Paolo Tosco
35d7320a51 - fixed build failure on Windows due to missing link to library (#1241) 2017-01-03 18:25:33 +01:00
Brian Kelley
06a0ef17aa Turns on -fpermissive for gcc >= 6 and boost < 1.62 (#1225) 2017-01-03 08:21:42 +01:00
Greg Landrum
6509e52611 Fixes #1230 (#1231)
* Fixes #1230

* add a test for cleanIt = False
2016-12-23 13:02:15 -05:00
Greg Landrum
ae774c4f24 add support the new sequence readers to wrappers (#1181) (#1221)
* Fixes #1181
needs more testing

* improved docs and a couple tests

* add the new sequence support to the java wrappers too
2016-12-21 04:42:17 +01:00
Greg Landrum
1ebe5ec39f Fixes #1219 (#1220) 2016-12-20 14:07:18 -05:00