Greetings,

I have a rather old code which was working with OpenBabel-2.4.1.
However, I yesterday switched to the latest development version (I
think VERSION 2.8.10) from github.

https://github.com/openbabel/openbabel

After installing it I got an ImportError saying that 'OBElementTable'
is missing. Was this table really removed, and if yes, how can I adapt
my code below to work with the latest version?

I thank you in advance.

Thomas



from openbabel.openbabel import OBElementTable
>
> # ELEMENT TABLE TO DETERMINE VDW AND COVALENT BONDS
> et = OBElementTable()
>
# CONVERT ELEMENT SYMBOLS TO ATOMIC NUMBERS
atomicnums = (et.GetAtomicNum(str(element)) for element in config['elements'])

# GET ATOM RADII FOR THE LIGAND ATOM
hetatm_cov = et.GetCovalentRad(hetatm.GetAtomicNum())
hetatm_vdw = et.GetVdwRad(hetatm.GetAtomicNum())

label = "{0}.{1}-B{2}".format(et.GetSymbol(x), et.GetSymbol(y), i)



-- 

======================================================================

Dr. Thomas Evangelidis

Research Scientist

IOCB - Institute of Organic Chemistry and Biochemistry of the Czech Academy
of Sciences <https://www.uochb.cz/web/structure/31.html?lang=en>, Prague,
Czech Republic
  &
CEITEC - Central European Institute of Technology
<https://www.ceitec.eu/>, Brno,
Czech Republic

email: teva...@gmail.com, Twitter: tevangelidis
<https://twitter.com/tevangelidis>, LinkedIn: Thomas Evangelidis
<https://www.linkedin.com/in/thomas-evangelidis-495b45125/>

website: https://sites.google.com/site/thomasevangelidishomepage/
_______________________________________________
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

Reply via email to