Some pdbs cannot be download from PDB using biopython, though they exist in PDB. It generates the error. This code is used to download pdb (2j8e) It could not download however it works for other pdbs.
Python 2.7.4 (default, May 14 2013, 09:41:12)
[GCC 4.4.6 20120305 (Red Hat 4.4.6-4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from Bio.PDB import PDBList
>>> pdbdownload = PDBList()
>>> pdbid = '2j8e'
>>> downloaded_path = pdbdownload.retrieve_pdb_file(pdbid)
Downloading PDB structure '2j8e'...
Traceback (most recent call last):
IOError: [Errno ftp error] [Errno ftp error] 550 Can't change directory to pdb2j8e.ent.gz: No such file or directory
This is an error. Has someone faced this problem?
I'm sorry, but that file doesn't exist! See by yourself:
ftp://ftp.wwpdb.org/pub/pdb/data/structures/divided/pdb/j8/
There are no pdb2j8e.ent.gz in that dir. If you try to download 2j8f or any other id, you get it without problem.
That file got obsolete, and can be retrieved from ftp://ftp.wwpdb.org/pub/pdb/data/structures/obsolete/pdb/j8/. With Biopython you can do:
downloaded_path = pdbdownload.retrieve_pdb_file(pdbid, obsolete=True)
Related
Installing pymqi in a MacOS M1 Pro 12.1 Monterey, Python 3.9.9 in a virtualenv and the usual suspect appeared again:
Traceback (most recent call last):
File "/Users/a.gounaris/.virtualenvs/mxhub39/lib/python3.9/site-packages/pymqi/__init__.py", line 132, in <module>
from . import pymqe # type: ignore
ImportError: dlopen(/Users/a.gounaris/.virtualenvs/mxhub39/lib/python3.9/site-packages/pymqi/pymqe.cpython-39-darwin.so, 0x0002): symbol not found in flat namespace '_MQBACK'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/Users/a.gounaris/.virtualenvs/mxhub39/lib/python3.9/site-packages/pymqi/__init__.py", line 134, in <module>
import pymqe # type: ignore # Backward compatibility
ModuleNotFoundError: No module named 'pymqe'
All paths are in place /opt/mqm/bin:/opt/mqm/samp/bin and Python sees the env variable os.environ['DYLD_LIBRARY_PATH']=='/opt/mqm/lib64'
After reinstalling pymqi with --verbose flag, this warning showed up:
ld: warning: ignoring file /opt/mqm/lib64/libmqic_r.dylib, building for macOS-arm64 but attempting to link with file built for macOS-x86_64
Might be the root cause of the exception symbol not found in flat namespace '_MQBACK' in M1 Pro Silicon platforms ?
It says that ibmqic_r.dylib is ignored.
Would a new release of MacOS Toolkit build for macOS-arm64 solve the issue?
Another option - theoretically speaking - could be to run the build for macOS-x86_64 with Rosetta 2 as suggested in this post, I don't know how to do it..
Any help will be mostly appreciated.
I cannot get tensorflow to install, this is the error message i'm getting:
dhcp-3-6:~ M$ python
Python 2.7.6 (default, Sep 9 2014, 15:04:36)
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Library/Python/2.7/site-packages/tensorflow/__init__.py", line 23, in <module>
from tensorflow.python import *
File "/Library/Python/2.7/site-packages/tensorflow/python/__init__.py", line 49, in <module>
from tensorflow.core.framework.graph_pb2 import *
File "/Library/Python/2.7/site- packages/tensorflow/core/framework/graph_pb2.py", line 10, in <module>
from google.protobuf import descriptor_pb2
File "/Library/Python/2.7/site-packages/google/protobuf/descriptor_pb2.py", line 1495, in <module>
options=None),
File "/Library/Python/2.7/site-packages/google/protobuf/descriptor.py", line 505, in __new__
return _message.default_pool.FindFieldByName(full_name)
KeyError: "Couldn't find field google.protobuf.GeneratedCodeInfo.Annotation.path"
I have tried many forms but still cannot see how to get it working. Could you please give me some guidance?
When running a Python script that contain import theano, I get this error:
===============================
00001 #include <Python.h>
00002 #include "structmember.h"
00003 #include <sys/time.h>
00004
00005 // Old Python compatibility from here:
00006 // http://www.python.org/dev/peps/pep-0353/
[...]
01077 return RETVAL;
01078 }
01079
01080
Problem occurred during compilation with the command line below:
C:\programming\cpp\gcc-4.9.2-tdm-1-core\bin\g++.exe -shared -g -D NPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -m64 -DMS_WIN64 -IC:\Anaconda\lib\site-packages\numpy\core\include -IC:\Anaconda\include -o C:\Users\Francky\AppData\Local\Theano\compiledir_Windows-7-6.1.7601-SP1-Intel64_Family_6_Model_58_Stepping_9_GenuineIntel-2.7.10-64\lazylinker_ext\lazylinker_ext.pyd C:\Users\Francky\AppData\Local\Theano\compiledir_Windows-7-6.1.7601-SP1-Intel64_Family_6_Model_58_Stepping_9_GenuineIntel-2.7.10-64\lazylinker_ext\mod.cpp -LC:\Anaconda\libs -LC:\Anaconda -lpython27
===============================
g++.exe: error: CreateProcess: No such file or directory
Traceback (most recent call last):
File "C:\Users\Francky\Documents\GitHub\nlp\6864project\code\theano\eval_dialog_cat.py", line 7, in <module>
import theano
File "c:\users\francky\downloads\theano-rel-0.7\theano-rel-0.7\theano\__init__.py", line 55, in <module>
from theano.compile import \
File "c:\users\francky\downloads\theano-rel-0.7\theano-rel-0.7\theano\compile\__init__.py", line 9, in <module>
from theano.compile.function_module import *
File "c:\users\francky\downloads\theano-rel-0.7\theano-rel-0.7\theano\compile\function_module.py", line 18, in <module>
import theano.compile.mode
File "c:\users\francky\downloads\theano-rel-0.7\theano-rel-0.7\theano\compile\mode.py", line 11, in <module>
import theano.gof.vm
File "c:\users\francky\downloads\theano-rel-0.7\theano-rel-0.7\theano\gof\vm.py", line 568, in <module>
import lazylinker_c
File "c:\users\francky\downloads\theano-rel-0.7\theano-rel-0.7\theano\gof\lazylinker_c.py", line 116, in <module>
preargs=args)
File "c:\users\francky\downloads\theano-rel-0.7\theano-rel-0.7\theano\gof\cmodule.py", line 2010, in compile_str
(status, compile_stderr.replace('\n', '. ')))
. ception: Compilation failed (return status=1): g++.exe: error: CreateProcess: No such file or directory
It looks like g++.exe: error: CreateProcess: No such file or directory is caused by the absence of the file C:\Users\Francky\AppData\Local\Theano\compiledir_Windows-7-6.1.7601-SP1-Intel64_Family_6_Model_58_Stepping_9_GenuineIntel-2.7.10-64\lazylinker_ext\lazylinker_ext.pyd. How am I supposed to get this file?
I have installed Theano in Anaconda Python 2.7.10 X64 as follows:
conda install mingw libpython
pip install theano
Then I changed the g++ compiler namely TDM-GCC MinGW Compiler so that it compiles to x64 (otherwise I get C:\Users\Francky\AppData\Local\Theano\compiledir_Windows-7-6.1.7601-SP1-Intel64_Family_6_Model_58_Stepping_9_GenuineIntel-2.7.10-64\lazylinker_ext\mod.cpp:1: sorry, unimplemented: 64-bit mode not compiled in).
From here.
Have you closed your Command window and opened a new one? Changes to your environment variables (via the standard Windows dialogue window) will not apply to open Command windows (you could set the variables separately and manually in an open Command window though).
If setting environment variables doesn't help, the other answers to the linked question may help.
I've spent a couple of days on this. Ultimately I had to update theano AFTER changing my G++ compiler to 64 bit (I used http://mingw-w64.org/doku.php). Windows "where" command makes it easy to see where the g++ is installed: where g++ gave me several locations including the 32bit version.
I'm running on a Macbook, OS X 10.6.4. I've installed the latest version of libusb 1.x and also libusb-compat. The example applications in libusb compile and run, no problems there so I am assuming that it's installed correctly. Libftdi also appears to install correctly, but it seems to be having trouble with libusb. I tried one of the example apps and I get this error message:
$ ./simple
dyld: lazy symbol binding failed: Symbol not found: _usb_init
Referenced from: /Users/Me/Downloads/libftdi-0.19/src/.libs/libftdi.1.dylib
Expected in: flat namespace
dyld: Symbol not found: _usb_init
Referenced from: /Users/Me/Downloads/libftdi-0.19/src/.libs/libftdi.1.dylib
Expected in: flat namespace
Trace/BPT trap
The assumption that libusb is to blame is because _usb_init is a libusb function, I found a post here that was along the same lines http://www.jedi.be/blog/2009/11/11/ruby-usb-libusb/ but for Ruby.
Trying to get things going with Pylibftdi,
Traceback (most recent call last):
File "blah/list_devices.py", line 4, in <module>
for device in Driver().list_devices():
File "/Library/Python/2.6/site-packages/pylibftdi/driver.py", line 61, in __init__
fdll = CDLL(ftdi_lib)
File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/ctypes/__init__.py", line 345, in __init__
self._handle = _dlopen(self._name, mode)
OSError: dlopen(/usr/local/lib/libftdi.dylib, 6): Symbol not found: _usb_bulk_read
Referenced from: /usr/local/lib/libftdi.dylib
Expected in: flat namespace
in /usr/local/lib/libftdi.dylib
Note that to get anything to even run using Pyftdi I had to install libftdi for i386 rather than x86_64 as default (throws up mach-o errors) - however, even installing libftdi 'normally' gives the OSErrors above. Any suggestions would be greatly appreciated.
I believe with libftdi 0.19 you're supposed to use libusb 0.1 (atleast according to thier web page. http://www.intra2net.com/en/developer/libftdi/download.php). There's a port of libftdi out there to use libusb 1.0 if you want. I've been using it for SYNC and ASYNC Fifos and its been working great.
http://developer.intra2net.com/git/?p=libftdi-1.0
git://developer.intra2net.com/libftdi-1.0
Good luck
I am trying to install SciPy following these instructions: http://www.scipy.org/Download
And constantly getting error to build them for OS X Lepeord 10.5.7:
dyld: lazy symbol binding failed: Symbol not found: _iconv_open
Referenced from: /usr/lib/libaprutil-1.0.dylib
Expected in: /opt/local/lib/libiconv.2.dylib
dyld: Symbol not found: _iconv_open
Referenced from: /usr/lib/libaprutil-1.0.dylib
Expected in: /opt/local/lib/libiconv.2.dylib
Traceback (most recent call last):
File "setup.py", line 82, in
FULLVERSION += svn_version()
File "setup.py", line 74, in svn_version
raise ValueError("Error while parsing svn version ?")
ValueError: Error while parsing svn version ?
Is it absolutely necessary for you to build SciPy from source? It seems like it would be much easier to install SciPy on Mac OS X Leopard by using the SciPy Superpack Installer (which is mentioned on the SciPy download page). That is how I installed SciPy, and I've never had any problems with it.
The reason it's failing is that you have things installed in your /opt/local which are interfering with the system libraries. libiconv is installed in /usr/lib
MacPorts has a habit of messing up things. Unsetting the DYLD_LIBRARY_PATH when you run (and when you use) libraries like this would fix it.