On Wed, 2006-11-01 at 02:59 +1100, Edward d'Auvergne wrote:
> > > > pymol.cartoon() doesn't work for me. The commands go to pymol (they
> > > > appear in the tcl gui at least) but have no apparent effect. Just doing:
> > > >
> > > > hide everything
> > > > show cartoon
> > > >
> > > > on the pymol cmd line has the expected effect.
> > >
> > > This could be a PyMOL version issue. Which version are you using?
> > > I'm using the open source v0.99rc6 version (that you have to compile
> > > yourself). The PyMOL 'cmd.hide()' function also works on the non open
> > > source binary build of the same version.
> > >
> >
> > I've tracked this one down. My PDB file is not in the current working
> > directory, so path details need to be stripped before the cmd.hide(),
> > cmd.show() functions. So I have:
> >
> > relax> pymol.view('test')
> > relax> PyMOL>reinitialise
> > Traceback (most recent call last):
> > File "/home/chris/bin/pymol/modules/pymol/parser.py", line 370, in
> > parse
> > exec(com2[nest]+"\n",pymol_names,pymol_names)
> > File "<string>", line 1, in ?
> > NameError: name 'reinitialise' is not defined
> > PyMOL>load ../abp_600MHz_tensorFrame.pdb
> > CmdLoad: "../abp_600MHz_tensorFrame.pdb" loaded as
> > "abp_600MHz_tensorFrame".
> >
> > This is all good so far... but:
> >
> > relax> pymol.cartoon('test')
> > relax> PyMOL>cmd.hide('everything','../abp_600MHz_tensorFrame')
> > PyMOL>cmd.show('cartoon','../abp_600MHz_tensorFrame')
> > PyMOL>util.cbss('../abp_600MHz_tensorFrame', 'red', 'yellow', 'green')
> >
> > fails because there is no such object (in pymol)
> > as ../abp_600MHz_tensorFrame. It should be
> >
> > cmd.hide('everything','abp_600MHz_tensorFrame')
> > etc.
>
> Ah. I think we need a new function within the IO file 'io.py'. Maybe
> something called 'self.file_root()'. It should be pretty simple to
> implement. Maybe split by the path separator 'path.sep', take the
> last element, split by '.', then return the first element of the new
> array. Would you like to have a go at adding it Chris? I won't have
> commit access for a while. A complementary function 'self.file_ext()'
> could be added for future use as well.
I've added the io.file_root() function to both the 1.3 line and
tensor_pdb branch, and made the fix to pymol.cartoon().
I deemed file_ext() a bit trivial to demand its own function, the
desired functionality being available as:
file_ext = os.path.splitext(file)[1]
>
>
> > > > And finally, if I do pymol.tensor_pdb(), then close pymol and then do
> > > > pymol.view() in the same run, I get the tensor back again (I was just
> > > > expecting to get my protein).
> > >
> > > This is a feature. The PyMOL functions have inherited the command
> > > history feature of the Molmol code. Any commands generated by relax
> > > are rerun if you reopen PyMOL from relax. There is the user function
> > > 'pymol.clear_history()' which I forgot to mention in the original
> > > email.
> >
> > Fine. As long as it is run aware. If I have different tensors (or
> > different structures?) in separate runs but the same relax instance
> > (full_analysis.py, eg.), I don't want the two getting confused when I
> > start looking at them. The fact that pymol.clear_history() doesn't take
> > a run argument suggests that there might be the potential for such
> > confussion?
>
> Well, it currently accepts the run argument but if you have a close
> look at the code, you'll see that the pymol and molmol IO pipes
> ('self.relax.data.pymol' and 'self.relax.data.molmol') aren't
> associated with a run. It's not worth worrying about as the proposed
> redesign of the relax data model will cause the IO pipes to be tied to
> a run.
>
> Oh, the IO pipes aren't to be confused with the part of the proposal
> about data pipes where 'runs' will be renamed 'pipes'.
>
> Edward
>
>
> P.S. I'll create a new post for the rest of your message.
>
_______________________________________________
relax (http://nmr-relax.com)
This is the relax-devel mailing list
[email protected]
To unsubscribe from this list, get a password
reminder, or change your subscription options,
visit the list information page at
https://mail.gna.org/listinfo/relax-devel