"pdb" not a recognised OpenBabel format (error)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

"pdb" not a recognised OpenBabel format (error)

Daniel Sindhikara
Hello,
  After a long hiatus I got back on this project. After following the instructions I successfully installed openbabel/pybel.
However, when I tried testing the program I got a funny error, "pdb is not a recognised OpenBabel format".

Enthought Python Distribution -- www.enthought.com
Version: 7.1-1 (64-bit)

Python 2.7.2 |EPD 7.1-1 (64-bit)| (default, Jul  3 2011, 15:56:02)
[GCC 4.0.1 (Apple Inc. build 5493)] on darwin
Type "packages", "demo" or "enthought" for more information.
>>> import pybel as pb
>>> testmolecule = pb.readfile("pdb","mai.pdb").next()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/sindhikara/Tools/openbabel-install/lib/python2.7/site-packages/pybel.py", line 90, in readfile
    raise ValueError("%s is not a recognised OpenBabel format" % format)
ValueError: pdb is not a recognised OpenBabel format


Further, checking the formats variable:
>>> pb.informats
{}

It was empty.
Any clues into why this would happen?

Thanks in advance!
-Dan


--
Dr. Daniel J. Sindhikara
Institute for Molecular Science
E-mail: [hidden email]
Website: http://sites.google.com/site/dansindhikara/
--

------------------------------------------------------------------------------
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better
price-free! And you'll get a free "Love Thy Logs" t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
_______________________________________________
OpenBabel-scripting mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
Reply | Threaded
Open this post in threaded view
|

Re: "pdb" not a recognised OpenBabel format (error)

Noel O'Boyle
Administrator
Does "obabel -H pdb" show the PDB format?

On 6 September 2011 07:16, Daniel Sindhikara <[hidden email]> wrote:

> Hello,
>   After a long hiatus I got back on this project. After following the
> instructions I successfully installed openbabel/pybel.
> However, when I tried testing the program I got a funny error, "pdb is not a
> recognised OpenBabel format".
>
> Enthought Python Distribution -- www.enthought.com
> Version: 7.1-1 (64-bit)
>
> Python 2.7.2 |EPD 7.1-1 (64-bit)| (default, Jul  3 2011, 15:56:02)
> [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> Type "packages", "demo" or "enthought" for more information.
>>>> import pybel as pb
>>>> testmolecule = pb.readfile("pdb","mai.pdb").next()
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File
> "/Users/sindhikara/Tools/openbabel-install/lib/python2.7/site-packages/pybel.py",
> line 90, in readfile
>     raise ValueError("%s is not a recognised OpenBabel format" % format)
> ValueError: pdb is not a recognised OpenBabel format
>
>
> Further, checking the formats variable:
>>>> pb.informats
> {}
>
> It was empty.
> Any clues into why this would happen?
>
> Thanks in advance!
> -Dan
>
>
> --
> Dr. Daniel J. Sindhikara
> Institute for Molecular Science
> E-mail: [hidden email]
> Website: http://sites.google.com/site/dansindhikara/
> --
>
> ------------------------------------------------------------------------------
> Special Offer -- Download ArcSight Logger for FREE!
> Finally, a world-class log management solution at an even better
> price-free! And you'll get a free "Love Thy Logs" t-shirt when you
> download Logger. Secure your free ArcSight Logger TODAY!
> http://p.sf.net/sfu/arcsisghtdev2dev
> _______________________________________________
> OpenBabel-scripting mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
>
>

------------------------------------------------------------------------------
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better
price-free! And you'll get a free "Love Thy Logs" t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
_______________________________________________
OpenBabel-scripting mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
Reply | Threaded
Open this post in threaded view
|

Re: "pdb" not a recognised OpenBabel format (error)

Daniel Sindhikara
Yes it recognizes it, when I check the binary in my unzip directory, however, it does not.

19:21:35 [danpc: ~/Downloads/openbabel-2.3.0/bin]$ obabel -H pdb
  Protein Data Bank format
Read Options e.g. -as
  s  Output single bonds only
  b  Disable bonding entirely
  c  Ignore CONECT records


Specification at: http://www.wwpdb.org/docs.html
19:21:39 [danpc: ~/Downloads/openbabel-2.3.0/bin]$ ./obabel -H pdb
Format type:  was not recognized


On Tue, Sep 6, 2011 at 7:07 PM, Noel O'Boyle <[hidden email]> wrote:
Does "obabel -H pdb" show the PDB format?

On 6 September 2011 07:16, Daniel Sindhikara <[hidden email]> wrote:
> Hello,
>   After a long hiatus I got back on this project. After following the
> instructions I successfully installed openbabel/pybel.
> However, when I tried testing the program I got a funny error, "pdb is not a
> recognised OpenBabel format".
>
> Enthought Python Distribution -- www.enthought.com
> Version: 7.1-1 (64-bit)
>
> Python 2.7.2 |EPD 7.1-1 (64-bit)| (default, Jul  3 2011, 15:56:02)
> [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> Type "packages", "demo" or "enthought" for more information.
>>>> import pybel as pb
>>>> testmolecule = pb.readfile("pdb","mai.pdb").next()
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File
> "/Users/sindhikara/Tools/openbabel-install/lib/python2.7/site-packages/pybel.py",
> line 90, in readfile
>     raise ValueError("%s is not a recognised OpenBabel format" % format)
> ValueError: pdb is not a recognised OpenBabel format
>
>
> Further, checking the formats variable:
>>>> pb.informats
> {}
>
> It was empty.
> Any clues into why this would happen?
>
> Thanks in advance!
> -Dan
>
>
> --
> Dr. Daniel J. Sindhikara
> Institute for Molecular Science
> E-mail: [hidden email]
> Website: http://sites.google.com/site/dansindhikara/
> --
>
> ------------------------------------------------------------------------------
> Special Offer -- Download ArcSight Logger for FREE!
> Finally, a world-class log management solution at an even better
> price-free! And you'll get a free "Love Thy Logs" t-shirt when you
> download Logger. Secure your free ArcSight Logger TODAY!
> http://p.sf.net/sfu/arcsisghtdev2dev
> _______________________________________________
> OpenBabel-scripting mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
>
>



--
Dr. Daniel J. Sindhikara
Institute for Molecular Science
E-mail: [hidden email]
Website: http://sites.google.com/site/dansindhikara/
--

------------------------------------------------------------------------------
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better
price-free! And you'll get a free "Love Thy Logs" t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
_______________________________________________
OpenBabel-scripting mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
Reply | Threaded
Open this post in threaded view
|

Re: "pdb" not a recognised OpenBabel format (error)

Noel O'Boyle
Administrator
Well, that's the reason right there. You have several Open Babel
installations, and there is interference. My advice is to delete all
of your Open Babel installations, including related Python files. Then
install the whole thing locally (including the Python bindings), set
your environment variables appropriately, and then test "obabel -H
pdb".

- Noel

On 6 September 2011 11:22, Daniel Sindhikara <[hidden email]> wrote:

> Yes it recognizes it, when I check the binary in my unzip directory,
> however, it does not.
>
> 19:21:35 [danpc: ~/Downloads/openbabel-2.3.0/bin]$ obabel -H pdb
>   Protein Data Bank format
> Read Options e.g. -as
>   s  Output single bonds only
>   b  Disable bonding entirely
>   c  Ignore CONECT records
>
>
> Specification at: http://www.wwpdb.org/docs.html
> 19:21:39 [danpc: ~/Downloads/openbabel-2.3.0/bin]$ ./obabel -H pdb
> Format type:  was not recognized
>
>
> On Tue, Sep 6, 2011 at 7:07 PM, Noel O'Boyle <[hidden email]> wrote:
>>
>> Does "obabel -H pdb" show the PDB format?
>>
>> On 6 September 2011 07:16, Daniel Sindhikara <[hidden email]> wrote:
>> > Hello,
>> >   After a long hiatus I got back on this project. After following the
>> > instructions I successfully installed openbabel/pybel.
>> > However, when I tried testing the program I got a funny error, "pdb is
>> > not a
>> > recognised OpenBabel format".
>> >
>> > Enthought Python Distribution -- www.enthought.com
>> > Version: 7.1-1 (64-bit)
>> >
>> > Python 2.7.2 |EPD 7.1-1 (64-bit)| (default, Jul  3 2011, 15:56:02)
>> > [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
>> > Type "packages", "demo" or "enthought" for more information.
>> >>>> import pybel as pb
>> >>>> testmolecule = pb.readfile("pdb","mai.pdb").next()
>> > Traceback (most recent call last):
>> >   File "<stdin>", line 1, in <module>
>> >   File
>> >
>> > "/Users/sindhikara/Tools/openbabel-install/lib/python2.7/site-packages/pybel.py",
>> > line 90, in readfile
>> >     raise ValueError("%s is not a recognised OpenBabel format" % format)
>> > ValueError: pdb is not a recognised OpenBabel format
>> >
>> >
>> > Further, checking the formats variable:
>> >>>> pb.informats
>> > {}
>> >
>> > It was empty.
>> > Any clues into why this would happen?
>> >
>> > Thanks in advance!
>> > -Dan
>> >
>> >
>> > --
>> > Dr. Daniel J. Sindhikara
>> > Institute for Molecular Science
>> > E-mail: [hidden email]
>> > Website: http://sites.google.com/site/dansindhikara/
>> > --
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Special Offer -- Download ArcSight Logger for FREE!
>> > Finally, a world-class log management solution at an even better
>> > price-free! And you'll get a free "Love Thy Logs" t-shirt when you
>> > download Logger. Secure your free ArcSight Logger TODAY!
>> > http://p.sf.net/sfu/arcsisghtdev2dev
>> > _______________________________________________
>> > OpenBabel-scripting mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
>> >
>> >
>
>
>
> --
> Dr. Daniel J. Sindhikara
> Institute for Molecular Science
> E-mail: [hidden email]
> Website: http://sites.google.com/site/dansindhikara/
> --
>

------------------------------------------------------------------------------
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better
price-free! And you'll get a free "Love Thy Logs" t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
_______________________________________________
OpenBabel-scripting mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
Reply | Threaded
Open this post in threaded view
|

Re: "pdb" not a recognised OpenBabel format (error)

Daniel Sindhikara
Noel,
  Thanks for the help. I deleted all versions of Openbabel then started from scratch. I now get a new error (after "100%" installing). I believe there is some incompatibility with my version of gcc (4.6). I'm not sure, however which version I should use, and which file to modify to point to a different gcc.
The error is: cc1plus: error: unrecognized command line option "-arch"

Sorry for all the questions!

Here are my commands and the full error info:

cmake ../openbabel-2.3.0 -DCMAKE_INSTALL_PREFIX=~/Tools/OBabel -DCMAKE_BUILD_TYPE=DEBUG -DEIGEN2_INCLUDE_DIR=/opt/local/include/eigen2 -DPYTHON_BINDINGS=ON

Using included inchi library.
GUI will not be built
-- Python bindings will be compiled
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/sindhikara/Downloads/build

13:26:36 [danpc: ~/Downloads/build]$ make && make install
[  0%] Building CXX object src/CMakeFiles/openbabel.dir/alias.o
...
[100%] Building CXX object test/CMakeFiles/test_unitcell.dir/unitcell.o
Linking CXX executable ../bin/test_unitcell
[100%] Built target test_unitcell
running build
running build_py
copying openbabel.py -> /Users/sindhikara/Downloads/build/scripts/pybuild
copying pybel.py -> /Users/sindhikara/Downloads/build/scripts/pybuild
running build_ext
building '_openbabel' extension
gcc -fno-strict-aliasing -fno-common -dynamic -arch x86_64 -isysroot /Developer/SDKs/MacOSX10.5.sdk -DNDEBUG -g -O3 -arch x86_64 -isysroot /Developer/SDKs/MacOSX10.5.sdk -I/Users/sindhikara/Downloads/openbabel-2.3.0/scripts/python/../../include -I../include -I/Library/Frameworks/EPD64.framework/Versions/7.1/include/python2.7 -c /Users/sindhikara/Downloads/openbabel-2.3.0/scripts/python/openbabel-python.cpp -o build/temp.macosx-10.5-x86_64-2.7/Users/sindhikara/Downloads/openbabel-2.3.0/scripts/python/openbabel-python.o
cc1plus: error: unrecognized command line option "-arch"
cc1plus: error: unrecognized command line option "-arch"
error: command 'gcc' failed with exit status 1
make[2]: *** [scripts/CMakeFiles/_openbabel] Error 1
make[1]: *** [scripts/CMakeFiles/_openbabel.dir/all] Error 2
make: *** [all] Error 2




On Tue, Sep 6, 2011 at 9:26 PM, Noel O'Boyle <[hidden email]> wrote:
Well, that's the reason right there. You have several Open Babel
installations, and there is interference. My advice is to delete all
of your Open Babel installations, including related Python files. Then
install the whole thing locally (including the Python bindings), set
your environment variables appropriately, and then test "obabel -H
pdb".

- Noel

On 6 September 2011 11:22, Daniel Sindhikara <[hidden email]> wrote:
> Yes it recognizes it, when I check the binary in my unzip directory,
> however, it does not.
>
> 19:21:35 [danpc: ~/Downloads/openbabel-2.3.0/bin]$ obabel -H pdb
>   Protein Data Bank format
> Read Options e.g. -as
>   s  Output single bonds only
>   b  Disable bonding entirely
>   c  Ignore CONECT records
>
>
> Specification at: http://www.wwpdb.org/docs.html
> 19:21:39 [danpc: ~/Downloads/openbabel-2.3.0/bin]$ ./obabel -H pdb
> Format type:  was not recognized
>
>
> On Tue, Sep 6, 2011 at 7:07 PM, Noel O'Boyle <[hidden email]> wrote:
>>
>> Does "obabel -H pdb" show the PDB format?
>>
>> On 6 September 2011 07:16, Daniel Sindhikara <[hidden email]> wrote:
>> > Hello,
>> >   After a long hiatus I got back on this project. After following the
>> > instructions I successfully installed openbabel/pybel.
>> > However, when I tried testing the program I got a funny error, "pdb is
>> > not a
>> > recognised OpenBabel format".
>> >
>> > Enthought Python Distribution -- www.enthought.com
>> > Version: 7.1-1 (64-bit)
>> >
>> > Python 2.7.2 |EPD 7.1-1 (64-bit)| (default, Jul  3 2011, 15:56:02)
>> > [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
>> > Type "packages", "demo" or "enthought" for more information.
>> >>>> import pybel as pb
>> >>>> testmolecule = pb.readfile("pdb","mai.pdb").next()
>> > Traceback (most recent call last):
>> >   File "<stdin>", line 1, in <module>
>> >   File
>> >
>> > "/Users/sindhikara/Tools/openbabel-install/lib/python2.7/site-packages/pybel.py",
>> > line 90, in readfile
>> >     raise ValueError("%s is not a recognised OpenBabel format" % format)
>> > ValueError: pdb is not a recognised OpenBabel format
>> >
>> >
>> > Further, checking the formats variable:
>> >>>> pb.informats
>> > {}
>> >
>> > It was empty.
>> > Any clues into why this would happen?
>> >
>> > Thanks in advance!
>> > -Dan
>> >
>> >
>> > --
>> > Dr. Daniel J. Sindhikara
>> > Institute for Molecular Science
>> > E-mail: [hidden email]
>> > Website: http://sites.google.com/site/dansindhikara/
>> > --
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Special Offer -- Download ArcSight Logger for FREE!
>> > Finally, a world-class log management solution at an even better
>> > price-free! And you'll get a free "Love Thy Logs" t-shirt when you
>> > download Logger. Secure your free ArcSight Logger TODAY!
>> > http://p.sf.net/sfu/arcsisghtdev2dev
>> > _______________________________________________
>> > OpenBabel-scripting mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
>> >
>> >
>
>
>
> --
> Dr. Daniel J. Sindhikara
> Institute for Molecular Science
> E-mail: [hidden email]
> Website: http://sites.google.com/site/dansindhikara/
> --
>



--
Dr. Daniel J. Sindhikara
Institute for Molecular Science
E-mail: [hidden email]
Website: http://sites.google.com/site/dansindhikara/
--

------------------------------------------------------------------------------
Using storage to extend the benefits of virtualization and iSCSI
Virtualization increases hardware utilization and delivers a new level of
agility. Learn what those decisions are and how to modernize your storage
and backup environments for virtualization.
http://www.accelacomm.com/jaw/sfnl/114/51434361/
_______________________________________________
OpenBabel-scripting mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
Reply | Threaded
Open this post in threaded view
|

Re: "pdb" not a recognised OpenBabel format (error)

Geoffrey Hutchison
  Thanks for the help. I deleted all versions of Openbabel then started from scratch. I now get a new error (after "100%" installing). I believe there is some incompatibility with my version of gcc (4.6). I'm not sure, however which version I should use, and which file to modify to point to a different gcc.
The error is: cc1plus: error: unrecognized command line option "-arch"

Well, I don't know much about the Enthought version of python, but that's an issue with a non-Apple version of gcc when compiling the Python extension. I'd look at the CMakeCache.txt file in your build directory and see:

PYTHON_EXECUTABLE:FILEPATH=/usr/bin/python2.7

My guess is that it's not the python you expect from Enthought, but the rest of Open Babel has been compiled by the GCC provided by either Enthought or MacPorts.

That's the confusion.

-Geoff

------------------------------------------------------------------------------
Using storage to extend the benefits of virtualization and iSCSI
Virtualization increases hardware utilization and delivers a new level of
agility. Learn what those decisions are and how to modernize your storage
and backup environments for virtualization.
http://www.accelacomm.com/jaw/sfnl/114/51434361/
_______________________________________________
OpenBabel-scripting mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting
Reply | Threaded
Open this post in threaded view
|

Re: "pdb" not a recognised OpenBabel format (error)

Daniel Sindhikara
OK sorry for taking so much time. I did get it to work. Basically I had to get gcc 4.6 off my system. After that it worked (with gcc 4.5.3)
Thanks all again for the help.
-Dan

On Fri, Sep 9, 2011 at 3:50 PM, Daniel Sindhikara <[hidden email]> wrote:
Geoff,
  That's basically the problem, but reversed. It does find the correct Enthought version of python, but for some reason Enthought chose to use gcc 4.0.1 to compile. This is getting difficult now. I don't think I can change the compiler in Enthought and recompile. Do the two versions of gcc need to be compatible? I can't find where this "-arch" option is to change it.  I can change the specs for cmake to point to gcc4.0.1 but I end up with other problems.
e.g.:
[ 49%] Building CXX object src/formats/CMakeFiles/cdxmlformat.dir/xml/xml.o
Linking CXX shared module ../../lib/cdxmlformat.so
ld: warning: in /opt/local/lib/libxml2.dylib, file was built for unsupported file format which is not the architecture being linked (i386)
Undefined symbols:
  "_xmlResetError", referenced from:
      OpenBabel::XMLConversion::ReadXML(OpenBabel::XMLBaseFormat*, OpenBabel::OBBase*)in xml.o
  "_xmlOutputBufferFlush", referenced from:
....






On Wed, Sep 7, 2011 at 5:03 PM, Geoff Hutchison <[hidden email]> wrote:
  Thanks for the help. I deleted all versions of Openbabel then started from scratch. I now get a new error (after "100%" installing). I believe there is some incompatibility with my version of gcc (4.6). I'm not sure, however which version I should use, and which file to modify to point to a different gcc.
The error is: cc1plus: error: unrecognized command line option "-arch"

Well, I don't know much about the Enthought version of python, but that's an issue with a non-Apple version of gcc when compiling the Python extension. I'd look at the CMakeCache.txt file in your build directory and see:

PYTHON_EXECUTABLE:FILEPATH=/usr/bin/python2.7

My guess is that it's not the python you expect from Enthought, but the rest of Open Babel has been compiled by the GCC provided by either Enthought or MacPorts.

That's the confusion.

-Geoff



--
Dr. Daniel J. Sindhikara
Institute for Molecular Science
E-mail: [hidden email]
Website: http://sites.google.com/site/dansindhikara/
--



--
Dr. Daniel J. Sindhikara
Institute for Molecular Science
E-mail: [hidden email]
Website: http://sites.google.com/site/dansindhikara/
--

------------------------------------------------------------------------------
Doing More with Less: The Next Generation Virtual Desktop
What are the key obstacles that have prevented many mid-market businesses
from deploying virtual desktops?   How do next-generation virtual desktops
provide companies an easier-to-deploy, easier-to-manage and more affordable
virtual desktop model.http://www.accelacomm.com/jaw/sfnl/114/51426474/
_______________________________________________
OpenBabel-scripting mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting