Re: Colvars Error?

From: David Minh (daveminh_at_gmail.com)
Date: Fri Oct 26 2012 - 22:02:12 CDT

Actually I am not entirely sure how long each simulation will be, because this is with a new docking method and I don't know what parameters will work best. It will definitely be over 100 steps, most likely 10,000 or 100,000, but possibly a nanosecond or more. It turns out for these simulations it takes ~2 s to load a grid and only ~3 s total to do 10,000 steps (and ~15 s to do 100,000). If I go with a relatively small number of steps then a significant fraction of the time will be spent loading the grid. But I suppose I should do the workaround first, as "premature optimization is the root of all evil."

On Oct 26, 2012, at 10:26 PM, JC Gumbart <gumbart_at_ks.uiuc.edu> wrote:

> As a workaround, can you just set up individual simulations for each? If you're running a few nanoseconds for each, anyway, I think grabbing the frames from the dcd directly will be more troublesome in the long run (e.g., making sense of the output of the new simulation).
>
>
> On Oct 26, 2012, at 1:20 PM, David Minh wrote:
>
>> Hi Giacomo,
>>
>> It doesn't work with tclForces either. I tried this first, and it was fine:
>>
>> tclForces on
>> tclForcesScript {
>> proc calcforces {} {
>> addenergy 10
>> }
>> }
>>
>> But then when I tried this,
>>
>> tclForces on
>> tclForcesScript {
>> set aid 1
>> addatom $aid
>>
>> proc calcforces {} {
>> global aid
>> loadcoords p
>> addforce $aid [list 0.001 0.001 0.001]
>> }
>> }
>>
>> It gives the same error. So the error must be related to "coorfile read" not properly reinitializing something necessary for both colvars and tclForces, but not necessary without it.
>>
>> About the side note, I am only doing 100 MD steps as a test. Actual calculations will use several nanoseconds, in which case the restraining potential will be quite necessary!
>>
>> Thanks,
>> David
>>
>> On Fri, Oct 26, 2012 at 1:56 PM, Giacomo Fiorin <giacomo.fiorin_at_gmail.com> wrote:
>> Hello David, does the loop work with tclForces? You don't need to convert the colvars configuration file into a script for tclForces, just any tcl script.
>>
>> The error comes from the shared code that enables colvars, tclForces, IMD, TMD and the symmetry constraints to add forces to the simulated system. The atomic data may not be properly reinitialized everytime you load in a new DCD frame and run 100 MD steps from that.
>>
>> On a side note, can I ask why you need a cylindrical constraint when you're only running 100 MD steps from each DCD frames?
>>
>> Giacomo
>>
>>
>> On Fri, Oct 26, 2012 at 12:13 PM, David Minh <daveminh_at_gmail.com> wrote:
>> Hello NAMD users and developers,
>>
>> I am having a strange issue related to colvars. I am trying to do a coorfile loop in my NAMD configuration file:
>>
>> coorfile open dcd {begin1.dcd}
>> while { ![coorfile read] } {
>> reinitvels $temperature
>> run 100
>> }
>> coorfile close
>>
>> It works fine if I remove the lines:
>>
>> colvars on
>> colvarsConfig gorgeCylinder.colvars
>>
>> Here are contents of gorgeCylinder.colvars:
>>
>> colvar {
>> name DistXY
>> upperWall 6.0
>> upperWallConstant 10.0
>> distanceXY {
>> main {
>> atomsFile {../../../ligands/AAA/ligand.grid.pdb}
>> atomsCol B
>> atomsColValue 1.0
>> }
>> ref {
>> dummyAtom (52.548195, 57.459400, 49.528568)
>> }
>> axis (-0.294390, -0.561701, 0.773192)
>>
>> }
>> }
>>
>> colvar {
>> name DistZ
>> lowerWall 3
>> upperWall 25
>> lowerWallConstant 10.0
>> upperWallConstant 10.0
>> distanceZ {
>> main {
>> atomsFile {../../../ligands/AAA/ligand.grid.pdb}
>> atomsCol B
>> atomsColValue 1.0
>> }
>> ref {
>> dummyAtom (52.548195, 57.459400, 49.528568)
>> }
>> axis (-0.294390, -0.561701, 0.773192)
>>
>> }
>> }
>>
>> Basically it keeps the molecule within a cylinder.
>>
>> If I include the colvars lines in the NAMD configuration file, the code runs for 100 steps and then says:
>>
>> FATAL ERROR: Got the wrong number of atoms
>> ------------- Processor 0 Exiting: Called CmiAbort ------------
>> Reason: FATAL ERROR: Got the wrong number of atoms
>>
>> Charm++ fatal error:
>> FATAL ERROR: Got the wrong number of atoms
>>
>> Any ideas on what could cause this? The error doesn't really make sense because it works fine without the colvars lines. Is the error really related to colvarsInput? I can't seem to put a colvarsInput into the tcl loop.
>>
>> Thanks,
>> David Minh
>>
>>
>

This archive was generated by hypermail 2.1.6 : Mon Dec 31 2012 - 23:22:12 CST