Project

General

Profile

Bug #134

The continue option to trjcat -settime does not always work

Added by Chris Neale over 12 years ago. Updated over 12 years ago.

Status:
Closed
Priority:
High
Assignee:
Erik Lindahl
Category:
analysis tools
Target version:
Affected version - extra info:
Affected version:
Difficulty:
uncategorized
Close

Description

trjcat -settime {c option} does not work as expected when appending to a file.
However it works correctly when writing a new file and when using -settime {specify #ps} after calculating the number of ps by hand.

I am using gromacs-3.3.1, single precision, installed manually (not with
apt-get) on ubuntu linux. Also reproduced on gromacs-3.3 and while using .trr in
place of .xtc files

To be more specific:
a.xtc (200ps) and b.xtc (800ps) were both produced using grompp with tinit=0.
a.xtc was produced with position restraints and b.xtc was unrestrained.

trjcat -f a.xtc b.xtc -o a.xtc -settime
(enter 0,c)
produces a file of 800ps (should have been 1000ps)

Summary of files and start times used:
File Start time Time step
---------------------------------------------------------
a.xtc 0.000 ps 1.000 ps
b.xtc Continue from last file
Will append to a.xtc rather than creating a new file
Last frame 200 time 200.000
Reading frame 0 time 0.000
lasttime 200
Reading frame 200 time 200.000
Continue writing frames from b.xtc t=201 ps, frame=0
Last frame 800 time 800.000 -> frame 500 time 701.000 ps
Last frame written was 599, time 800.000000 ps

However, it works correctly when I write to a different file
trjcat -f a.xtc b.xtc -o c.xtc -settime
(enter 0,c)
correctly produces a file of 1000ps

Summary of files and start times used:
File Start time Time step
---------------------------------------------------------
a.xtc 0.000 ps 1.000 ps
b.xtc Continue from last file
Reading frame 0 time 0.000
lasttime -12345
Continue writing frames from a.xtc t=0 ps, frame=0
Last frame 200 time 200.000 -> frame 200 time 200.000 ps
Reading frame 0 time 0.000
lasttime 200
Reading frame 1 time 1.000
Continue writing frames from b.xtc t=201 ps, frame=201
Last frame 800 time 800.000 -> frame 1000 time 1000.000 ps
Last frame written was 1000, time 1000.000000 ps

The problem can be corrected by using entering 0,200 instead of 0,c to the
-settime option of trjcat.

Summary of files and start times used:
File Start time Time step
---------------------------------------------------------
a.xtc 0.000 ps 1.000 ps
b.xtc 200.000 ps 1.000 ps
Will append to a.xtc rather than creating a new file
Last frame 200 time 200.000
Reading frame 0 time 0.000
lasttime 200
Reading frame 1 time 1.000
Continue writing frames from b.xtc t=201 ps, frame=0
Last frame 800 time 800.000 -> frame 700 time 901.000 ps
Last frame written was 799, time 1000.000000 ps

gmxcheck -f a.xtc confirms that the timestamp is good "Last frame 200
time 200.000"


Related issues

Is duplicate of GROMACS - Bug #135: The continue option to trjcat -settime does not always workClosed03/13/2007

History

#1 Updated by David van der Spoel over 12 years ago

  • This bug has been marked as a duplicate of 135 ***

Also available in: Atom PDF