"b" option in INOPTIONS in python

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

"b" option in INOPTIONS in python

devw
Hi, I have some python code I'm working with, parts of which were written by someone else, including the bit I'm currently struggling with.

The code has a flag, babel_bond, which is described in the Help as "tells open babel to automatically calculate bonds". Overall this code has been working, in other words, when True, open babel does indeed calculate bonds for files with no bond information, and when False it does not.

Its sole usage in the code is:
        conv = OBConversion()
        if not babel_bond:
            conv.SetOptions("b", conv.INOPTIONS)

The bond detection behavior has been acting up recently and as part of the problem solving process I've been trying to find any documentation whatsoever about this "b" option being set in INOPTIONS.

All I've found is

"-b Convert dative bonds (e.g. [N+]([O-])=O to N(=O)=O)"

Which does not seem to have any connection to the actual behavior in the code.

Does anyone know what this "b" option is or how it works?

Thanks
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: "b" option in INOPTIONS in python

Noel O'Boyle
Administrator
That's a read option for reading a particular format. See the docs for info on options for different formats.

On 30 Jul 2017 9:31 a.m., "devw" <[hidden email]> wrote:
Hi, I have some python code I'm working with, parts of which were written by
someone else, including the bit I'm currently struggling with.

The code has a flag, babel_bond, which is described in the Help as "tells
open babel to automatically calculate bonds". Overall this code has been
working, in other words, when True, open babel does indeed calculate bonds
for files with no bond information, and when False it does not.

Its sole usage in the code is:
        conv = OBConversion()
        if not babel_bond:
            conv.SetOptions("b", conv.INOPTIONS)

The bond detection behavior has been acting up recently and as part of the
problem solving process I've been trying to find any documentation
whatsoever about this "b" option being set in INOPTIONS.

All I've found is

"-b Convert dative bonds (e.g. [N+]([O-])=O to N(=O)=O)"

Which does not seem to have any connection to the actual behavior in the
code.

Does anyone know what this "b" option is or how it works?

Thanks



--
View this message in context: http://forums.openbabel.org/b-option-in-INOPTIONS-in-python-tp4660139.html
Sent from the General discussion mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
OpenBabel-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
OpenBabel-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: "b" option in INOPTIONS in python

devw
This post has NOT been accepted by the mailing list yet.
as stated, I already read the docs available for this, and the description given doesn't match the actual behavior received when INOPTIONS "b" is set. Hence my looking for either more updated documentation or, better, someone who can explain what is actually going on in the code cited.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: "b" option in INOPTIONS in python

devw
This post has NOT been accepted by the mailing list yet.
To be more explicit, it's not for a particular format, it has an effect on how babelbond reads many formats, and that effect is not as stated in the documentation i could find that mentioned b.
Loading...