Previous Thread
Next Thread
Print Thread
cor2pdb.inp
#4014 11/03/04 01:09 AM
Joined: May 2004
Posts: 222
C
chuan Offline OP
Forum Member
OP Offline
Forum Member
C
Joined: May 2004
Posts: 222
* Convert cor trajectory to pdb format
* Author: Hock-Chuan YEO
*

set FILE 125l
set N 1

set START 100500 !starting frame no.
set END 333000 !ending frame no.
set INCR 500 !change in frame no. from one frame to the next
calc LOOP = @END-@START

read rtf card name $TOPPAR/top_all27_prot_lipid.rtf
read para card name $TOPPAR/par_all27_prot_lipid.prm

! Get starting psf and coordinates
open read formatted unit 3 name @FILE-solv.psf
read psf card unit 3
open unit 4 card read name @FILE_0.crd
read coor card unit 4

open unit 67 write form name @FILE-@N-cor.pdb !output pdb trajectory
open unit 31 read unform name @FILE-@N.cor !input cor trajectory
traj iread 31 nrea 1 begin @START stop @END skip @INCR

set tr @INCR

LABEL ILP
traj read
write coor pdb unit 67
incr tr by @INCR
if tr .le. @LOOP goto ILP

stop


CHARMM 30b1 driven by 1/ Xeon (32 bits) 2/ Redhat 7.3 (32 bits) with a Quadrics-modified 2.4-18-5 kernel 3/ Chuan, with 95% of the mentorship coming from great scientists frequenting this forum. 4/ Gracious support from the forum.
Re: cor2pdb.inp
chuan #4015 01/09/07 11:04 AM
Joined: Nov 2005
Posts: 19
S
Forum Member
Offline
Forum Member
S
Joined: Nov 2005
Posts: 19
Hi
When I run the above script the program tterminates without giving the error message. It does save the first frame.
INPUT FILE
* Convert cor trajectory to pdb format
* Author: Hock-Chuan YEO
*

set FILE finalmodel_heat_2

set START 110000 !starting frame no.
set END 120000 !ending frame no.
set INCR 1000 !change in frame no. from one frame to the next
calc LOOP = @END-@START

! Read in Topology and Parameter files(with new restraints in thirdset)

open unit 1 card read name top_all22_prot_cmap.inp
read RTF card unit 1
close unit 1


open unit 1 card read name par_all22_prot_cmap.inp
read PARA card unit 1
close unit 1


! Get starting psf and coordinates
open read formatted unit 27 name finalmodel.psf
read psf card unit 27
open read formatted unit 27 name @FILE.pdb
read coor pdb unit 27

open unit 67 write form name @FILE_cor.pdb !output pdb trajectory
open unit 50 read unform name @FILE.dcd !input cor trajectory
traj iread 50 nrea 1 begin @START stop @END skip @INCR

set tr @INCR

LABEL ILP
traj read
write coor pdb unit 67
* frame @INCR
*
incr tr by @INCR
if tr .le. @LOOP goto ILP

STOP

OUTPUT FILE
CHARMM> set tr @INCR
Parameter: INCR -> "1000"
Parameter: TR <- "1000"

CHARMM>

CHARMM> LABEL ILP

CHARMM> traj read

READING TRAJECTORY FROM UNIT 50
NUMBER OF COORDINATE SETS IN FILE: 600
NUMBER OF PREVIOUS DYNAMICS STEPS: 60100
FREQUENCY FOR SAVING COORDINATES: 100
NUMBER OF STEPS FOR CREATION RUN: 60000

TITLE> * CHARMM INPUT FILE FOR SYSTEM HEATING
TITLE> * DATE: 1/ 8/ 7 15: 5: 0 CREATED BY USER: svohra
TITLE> *

CHARMM> write coor pdb unit 67
RDTITL> * FRAME 1000
RDTITL> *

CHARMM> incr tr by @INCR
Parameter: INCR -> "1000"
Parameter: TR <- "2000"

CHARMM> if tr .le. @LOOP goto ILP
Parameter: LOOP -> "10000"
Comparing "2000" and "10000".
IF test evaluated as true. Performing command

ANY HELP IS APPRECIATED

Thanks

Re: cor2pdb.inp
svohra #4016 01/10/07 10:29 AM
Joined: Sep 2003
Posts: 4,794
Likes: 2
Forum Member
Online Content
Forum Member
Joined: Sep 2003
Posts: 4,794
Likes: 2
The script probably needs to open a new PDB file for each frame; I do not know if this is related to your problem. If you are using MPI it may be that it is the old stdin rewind MPI problem you have run into. See parallel.doc for a workaround.


Lennart Nilsson
Karolinska Institutet
Stockholm, Sweden

Moderated by  lennart, rmv 

Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.4
(Release build 20200307)
Responsive Width:

PHP: 5.6.33-0+deb8u1 Page Time: 0.011s Queries: 20 (0.005s) Memory: 0.9049 MB (Peak: 0.9771 MB) Data Comp: Off Server Time: 2020-09-29 00:48:59 UTC
Valid HTML 5 and Valid CSS