From: Thomas H. <tho...@sc...> - 2013-03-20 10:47:13
|
Hi Bharat, you should run python scripts from within PyMOL using the "run" command: http://pymolwiki.org/index.php/Running_Scripts Or follow these examples if you really need to launch PyMOL from a python session (not recommended for beginners): http://pymolwiki.org/index.php/Launching_From_a_Script Cheers, Thomas bharat gupta wrote, On 03/20/13 03:23: > Hi, > > I am a newbie in python scripting from pymol. I am getting the following > error while using the command cmd.load :- > > from pymol import cmd > > print "Current PyMoL Directory:", cmd.pwd() > cmd.load ("1A73.pdb") > > Error:- > ---------- > Traceback (most recent call last): > File "test.py", line 5, in <module> > cmd.load ("1A73.pdb") > File "/usr/lib/python2.7/site-packages/pymol/importing.py", line 872, > in load > _self.unlock(r,_self) > File "/usr/lib/python2.7/site-packages/pymol/locking.py", line 79, in > unlock > if (thread.get_ident() == pymol.glutThread): > AttributeError: 'module' object has no attribute 'glutThread' > > ------------ > Bharat -- Thomas Holder PyMOL Developer Schrödinger Contractor |