Re: AMBER: Trimming ptraj output

From: Andy Purkiss <a.purkiss.mail.cryst.bbk.ac.uk>
Date: Fri, 13 Jan 2006 18:03:54 +0000

On Fri, 2006-01-13 at 10:37 -0700, Thomas E. Cheatham, III wrote:
> > I'm switching over to use ptraj from carnal. Carnal has an option in the
> > FILES_OUT section allowing the user to only output every n snapshots:
> >
> > e.g.
> > COORD crd ./nowat.crd CRD MOD n;
> >
> > Is there a way to do this with ptraj, other than by altering the trajin
> > lines? I don't want to do this as this will affect the analysis of rmsd
> > etc.
>
> At present, no, but this is a good idea; I've often had the problem of
> wanting every 10th frame, yet my trajin coordinates are not necessarily
> divisible by 10 so it is a nightmare to set up the trajin. The easy
> alternative is simply to allow specification of this on the trajout. I
> should have thought of that :-)
>

Fortunately my input is divisible by 10, so I can do this.

> It would also be nice to have multiple trajout commands (this will be
> ready soon).
>

This will be very useful, combined with a MOD type option. I use pdb
files for running other analysis programs and it is a shame to run ptraj
two times.

> > Also, a question to the author. Is it possible to stop ptraj checking
> > all the input files at the beginning of the run. My trajin files are
>
> I agree that the checking is tedious and I have a version in the works
> that avoids this. The new AMBER release will also support a NetCDF binary
> file that will also alleviate some of these issues (with size, accuracy
> and speed of processing).
>
> > Maybe just a simple check that the file exists would be possible rather
>
> The reason I check at present is to figure out how many frames are present
> so I can allocate memory; the new way is to allocate memory in blocks
> (say 1000 frames) and if you blow memory, expand it (realloc).
>

Ahh, I assumed that the memory allocation was already dynamic!

> > than a complete run though as this didn't catch my mistake with
> > mismatched parameter and trajectory files!!
>
> To avoid this, I usually do a simple run with one trajin line with 1 2 1
> appended (i.e. only do 2 frames). Not perfect, but it works. The new
> version will be available with the release of AMBER 9.0 slated for March
> 2006.
>

As an aside, I have modified my local version of ptraj to read in bzip2
(.bz2 suffix) compressed files. These are more compressed than gzipped
files, but the algorithm is more cpu intensive and the bzip2 command
understands most gzip options.

This only required a few alterations to the io.c file and I would be
grateful if you could include bzip2 compatibility in the next release. I
can supply a patched version of io.c if needs be.

Andy

> --tom
>
> \-/ Thomas E. Cheatham, III (Assistant Professor) College of Pharmacy
> -/- Departments of Med. Chem. and of Pharmaceutics and Pharm. Chem.
> /-\ Adjunct Asst Prof of Bioeng.; Center for High Performance Computing
> \-/ University of Utah, 30 S 2000 E, SH 201, Salt Lake City, UT 84112
> -/-
> /-\ tec3.utah.edu (801) 587-9652; FAX: (801) 585-9119
> \-/ BPRP295A http://www.chpc.utah.edu/~cheatham
>
> -----------------------------------------------------------------------
> The AMBER Mail Reflector
> To post, send mail to amber.scripps.edu
> To unsubscribe, send "unsubscribe amber" to majordomo.scripps.edu
-- 
Cat, n.: Lapwarmer with built-in buzzer.
+---------------------------------------------------------------------+
|  Andy Purkiss, School of Crystallography, Birkbeck College, London  |
|           E-mail   a.purkiss.mail.cryst.bbk.ac.uk                   |
|      Phone 020 7631 6869 (Work) or 0776 490 360 (Mobile)            |
+---------------------------------------------------------------------+
-----------------------------------------------------------------------
The AMBER Mail Reflector
To post, send mail to amber.scripps.edu
To unsubscribe, send "unsubscribe amber" to majordomo.scripps.edu
Received on Sat Jan 14 2006 - 06:10:07 PST
Custom Search