Re: [GaMD-discuss] error with amber24 GaMD-PPI Too many TI atoms--current limit: 500 atoms
Brought to you by:
yinglongmiao
|
From: Christian S. <cgs...@gm...> - 2025-11-10 21:07:54
|
Hi Yinglong,
Thanks for the suggestions. I have tried several things so far, let me
recap them. My system contains 1,951 heavy atoms (3,814 atoms total) in the
TI region, which I am calling through timask1 = ':1870-2126!@H' and scmask1
= ':1870-2126!@H' in an input file to run GaMD-PPI.
1) I compiled a standard, unmodified build of amber24. When I put a large
system into that build to run GaMD-PPI, I get an error saying that the TI
atom limit is 500 atoms. Thus I need to expand the TI atom limit.
2) I tried changing the "MaxNumberTIAtom", "MaxNumberTIPair", and
"MaxNumberREAFAtom"
within $AMBERHOME/amber/pmemd24_src/src/pmemd/src/gti_controlVariable.i. I
increased these atom limits as shown below, recompiled a fresh version of
amber24, and still found the same error, saying the atom limit in TI was
500.
MaxNumberTIAtom = 750 -> 5250
MaxNumberTIPair = 300 -> 3000
MaxNumberREAFAtom = 500 -> 4000
3) The "MaxNumberTIAtom2"
within $AMBERHOME/amber/pmemd24_src/src/pmemd/src//cuda/gti_NBList_kernels.cu
comes with a limit of 4000, which should be enough for this system.
static const int MaxNumberTIAtom2 = 4000
I did not try increasing that.
Do you have any idea what might be overwriting these other variables to
enforce a smaller TI atom limit? I'm thinking the error message, stating
there's a TI atom limit of 500, is probably not tied to the actual TI atom
limit - I'm guessing that if one made the TI atom limit to be 2 atoms, the
error message would still say the TI atom limit is 500. But I cannot figure
out what variable is actually controlling the TI atom limit, or how to
increase that. Or perhaps there's some issue with how I'm telling GaMD-PPI
to select my TI atoms, and it's selecting more than I want? I can send my
input files or system files if that helps, or can try any other ideas you
have to get this to run. Thanks for your help!
Best,
Christian
On Mon, Nov 10, 2025 at 6:11 AM Miao, Yinglong <Yin...@me...>
wrote:
> Hi Christian,
>
> The related parameters should be defined in file
> *$AMBERHOME/src/pmemd/src/gti_controlVariable.i*. I compared this file in
> our "gamd" branch with master branch in the Amber git repository:
>
> *# AMBER “gamd"*
>
> * STATIC_CONST_INT MaxNumberTIAtom **=* *4000**;*
>
> * STATIC_CONST_INT MaxNumberTIPair **=* *3000**;*
>
> STATIC_CONST_INT MaxNumberNBPerAtom = 3072;
>
>
> * STATIC_CONST_INT MaxNumberREAFAtom **=* *5000**;*
>
> STATIC_CONST_INT MaxNumberRMSDAtom = 200;
>
> STATIC_CONST_INT MaxNumberRMSDRegion = 5;
>
>
>
> *# AMBER master*
>
>
> STATIC_CONST_INT MaxNumberTIAtom = 750;
>
> STATIC_CONST_INT MaxNumberTIPair = 300;
>
> STATIC_CONST_INT MaxNumberNBPerAtom = 3072;
>
>
> STATIC_CONST_INT MaxNumberREAFAtom = 500;
>
> STATIC_CONST_INT MaxNumberRMSDAtom = 200;
>
> STATIC_CONST_INT MaxNumberRMSDRegion = 5;
>
> Three parameters “*MaxNumberTIAtom*”, “*MaxNumberTIPair*” and “
> *MaxNumberREAFAtom*” are modified. Could you help to try those values as
> used in the “gamd” branch to see if that resolves the issue?
>
> Thanks,
> Yinglong
>
>
>
> On Nov 9, 2025, at 11:44 AM, Miao, Yinglong <Yin...@me...>
> wrote:
>
> Hi Christian,
>
> Seems you are changing these variables in the wrong direction. You need to *
> increase* *MaxNumberTIAtom *and *MaxNumberTIAtom2 *to a number greater
> than 500, like 4000 or the number of atoms in your protein 1 for simulation.
>
> Hope this helps,
> Yinglong
>
>
>
> On Nov 5, 2025, at 5:16 PM, Christian Seitz <cgs...@gm...> wrote:
>
> Hi Yinglong,
>
> Thanks, as a test I reduced the limit in
> $AMBERHOME/amber/pmemd24_src/src/pmemd/src//cuda/gti_NBList_kernels.cu from
> 4000 to 400:
>
> static const int MaxNumberTIAtom2 = 4000 -> 400
>
> After building a fresh install of amber24 with this reduced atom limit, I
> found that the TI atom limit remained at 500. If it helps, inside
> $AMBERHOME/amber/pmemd24_src/src/pmemd/src/cuda/gti_gpuContext.cpp one can
> find this snippet:
>
> if (TISize > gti_simulationConst::MaxNumberTIAtom) {
> std::string e("Too many TI atoms--current limit: 500 atoms");
> throw std::runtime_error(e);
>
> I can only find TISize
> in $AMBERHOME/amber/pmemd24_src/src/pmemd/src/cuda/gti_gpuContext.cpp. I
> have tried grepping a variety of terms
> within $AMBERHOME/amber/pmemd24_src/src/pmemd/src, such as "500",
> "TIAtoms", and "TISize", but nothing amongst these stand out to my
> non-expert eyes to change. When I ask chatgpt or claude how to solve this,
> they simply refer to the forum posts in my initial email, including this
> post, and suggest searching through non-existent files. Do you have any
> other ideas on where to search or what to look for? Thanks for your help!
>
> Best,
> Christian
>
>
> On Mon, Nov 3, 2025 at 7:57 PM Miao, Yinglong <Yin...@me...>
> wrote:
>
>> Hi Christian,
>>
>> This is what I found for “MaxNumberTIAtom” in the pmemd src code:
>>
>> *~/amber-git/src/pmemd/src*$ grep -iR "MaxNumberTIAtom" *
>> cuda/gti_NBList_kernels.cu: __shared__ volatile float
>> coordTI[gti_simulationConst::*MaxNumberTIAtom*][3];
>> cuda/gti_NBList_kernels.cu: __shared__ float
>> coordTI[gti_simulationConst::*MaxNumberTIAtom*][3];
>> cuda/gti_NBList_kernels.cu: __shared__ volatile float
>> coordTI[gti_simulationConst::*MaxNumberTIAtom*][3];
>> *cuda/gti_NBList_kernels.cu: static const int MaxNumberTIAtom2 = 4000;*
>> cuda/gti_NBList_kernels.cu:// __shared__ volatile bool
>> bondMask[(gti_simulationConst::*MaxNumberTIAtom*2 + 1) *
>> cuda/gti_NBList_kernels.cu://
>> gti_simulationConst::*MaxNumberTIAtom*2];
>> cuda/gti_NBList_kernels.cu:// __shared__ volatile float
>> coordTI[gti_simulationConst::*MaxNumberTIAtom*2][3];
>> cuda/gti_NBList_kernels.cu: __shared__ volatile bool bondMask[(
>> *MaxNumberTIAtom*2 + 1) *
>> cuda/gti_NBList_kernels.cu:
>> *MaxNumberTIAtom*2];
>> cuda/gti_NBList_kernels.cu: __shared__ volatile float coordTI[
>> *MaxNumberTIAtom*2][3];
>> cuda/gti_gpuContext.cpp: uint4 *temp = new uint4[gti_simulationConst::
>> *MaxNumberTIAtom*];
>> cuda/gti_gpuContext.cpp: unsigned* tempSC = new
>> unsigned[gti_simulationConst::*MaxNumberTIAtom**2];
>> cuda/gti_gpuContext.cpp: unsigned tempShift = gti_simulationConst::
>> *MaxNumberTIAtom*;
>> cuda/gti_gpuContext.cpp: if (TISize > gti_simulationConst::
>> *MaxNumberTIAtom*) {
>> cuda/gti_gpuContext.cpp: int tempList[gti_simulationConst::
>> *MaxNumberTIAtom*];
>> *gti_controlVariable.i: STATIC_CONST_INT MaxNumberTIAtom = 4000;*
>> ti.F90: !!integer, parameter::*MaxNumberTIAtom*=500 !! this must be
>> consistent w/ gti_controlVariable.i
>>
>> Maybe you can check *MaxNumberTIAtom2 in **cuda/gti_NBList_kernels.cu *as
>> well?
>>
>> Best,
>> Yinglong
>>
>>
>> On Oct 31, 2025, at 6:28 PM, Christian Seitz <cgs...@gm...> wrote:
>>
>> Hi Yinglong,
>>
>> Thanks for the helpful example, I tried a couple more things:
>> 1) I tried compiling amber24 in several different places, all while
>> editing the
>> $AMBERHOME/amber/pmemd24_src/src/pmemd/src/gti_controlVariable.i file to
>> match what you sent. Each time I tried a run, I found the error saying the
>> TI atom limit is 500.
>> 2) I tried compiling amber24 without editing any files. This means the
>> default MaxNumberTIAtom is 750 inside
>> $AMBERHOME/amber/pmemd24_src/src/pmemd/src/gti_controlVariable.i. When I
>> try to run GaMD-PPI with this version, my system still crashes with a TI
>> atom limit of 500.
>>
>> Am I missing something? In amber24 is there another variable that
>> overrides the limits set inside the gti_controlVariable.i file? If so, that
>> would explain why running GaMP-PPI shows an atom limit of 500 even though
>> the default amber24 TI atom limit inside gti_controlVariable.i is 750. In
>> 2) the only file I edited was the
>> $AMBERHOME/amber/pmemd24_src/build/run_cmake file, where I edited the linux
>> section to be
>>
>> cmake $AMBER_PREFIX/pmemd24_src \
>> -DCMAKE_INSTALL_PREFIX=$AMBER_PREFIX/pmemd24 \
>> -DCOMPILER=MANUAL \
>> -DMPI=TRUE -DCUDA=TRUE -DINSTALL_TESTS=TRUE \
>> -DDOWNLOAD_MINICONDA=FALSE -DBUILD_PYTHON=FALSE \
>> -DBUILD_PERL=FALSE -DBUILD_GUI=FALSE \
>> -DPMEMD_ONLY=TRUE -DCHECK_UPDATES=FALSE \
>> -DDISABLE_TOOLS=FEW -DCMAKE_C_COMPILER=gcc-12 \
>> -DCMAKE_CXX_COMPILER=g++-12 -DCMAKE_Fortran_COMPILER=gfortran-12 \
>> 2>&1 | tee cmake.log
>>
>> to compile on the resource I am using. Let me know if there are any files
>> I can send to help diagnose this~
>>
>> Best,
>> Christian
>>
>> On Thu, Oct 30, 2025 at 10:56 AM Miao, Yinglong <
>> Yin...@me...> wrote:
>>
>>> Hi Christian,
>>>
>>> Sorry for the issue with running PPI-GaMD. To perhaps follow up with the
>>> post by Dr. Fabian Glaser as you mentioned in your email, I’m attaching
>>> more detailed discussion he had later on with Jinan to resolve the issue.
>>>
>>> Hope the example “gti_controlVariable.i” and the idea of using “only the
>>> interfacial atoms of the first protein in TIMASK1/SCMASK1, and then the
>>> second FULL protein first and last atoms in bgpro2atm and edprod2atm” could
>>> help.
>>>
>>> For “bgpro2atm and edpro2atm”, it would make sense to include ALL atoms
>>> associated with the second protein, including the PTMs.
>>>
>>> Best,
>>> Yinglong
>>>
>>>
>>>
>>> Yinglong Miao, Ph.D.
>>> Associate Professor
>>> Department of Pharmacology and
>>> Computational Medicine Program
>>> University of North Carolina - Chapel Hill
>>> Tel: 1-919-962-5696
>>> http://miaolab.org
>>>
>>> Editor-in-Chief
>>> *npj Drug Discovery*
>>> https://www.nature.com/npjdrugdiscov
>>>
>>> On Oct 29, 2025, at 5:03 PM, Christian Seitz <cgs...@gm...>
>>> wrote:
>>>
>>> You don't often get email from cgs...@gm.... Learn why this is
>>> important <https://aka.ms/LearnAboutSenderIdentification>
>>> Hello Yinglong + co,
>>>
>>> I am trying to equilibrate a system for use in GaMD-PPI using amber24. I
>>> ran it through normal equilibration for MD (heating, minimizing,
>>> equilibration) already. I tried to start a GaMD equilibration, but
>>> immediately the system fails with a segfault:
>>>
>>> terminate called after throwing an instance of 'std::runtime_error'
>>> what(): Too many TI atoms--current limit: 500 atoms
>>>
>>> I went
>>> into $AMBERHOME/amber/pmemd24_src/src/pmemd/src/gti_controlVariable.i and
>>> changed the following parameters:
>>>
>>> MaxNumberTIAtom = 750 -> 5250
>>> MaxNumberTIPair = 300 -> 3000
>>> MaxNumberREAFAtom = 500 -> 4000
>>>
>>> I can make a fresh build of amber24 and compile with these adjusted
>>> parameters, but running it still results in a TI atom limit of 500 atoms.
>>> This issue was seen previously here
>>> <http://archive.ambermd.org/202412/0029.html>, here
>>> <https://sourceforge.net/p/gamd/mailman/gamd-discuss/thread/SA1PR03MB6450A4FB3834171AE436C154B85F2%40SA1PR03MB6450.namprd03.prod.outlook.com/#msg58743189>
>>> , here <http://archive.ambermd.org/202206/0050.html>, and here
>>> <http://archive.ambermd.org/202307/0086.html>. It appears one person
>>> <https://sourceforge.net/p/gamd/mailman/gamd-discuss/thread/36223A2E-0AC1-4D6B-8F42-E1B5C996FE4F%40uconn.edu/>
>>> was able to fix this issue in a previous version of amber, but not
>>> amber24. Do you have any ideas on what other parameters I would need to
>>> modify to increase the TI atom limit? Thank you!
>>>
>>> I also have a question about the atom masks. When I select the atom mask
>>> bgpro2atm and edpro2atm, should this mask only include protein atoms or
>>> also PTMs, such as glycans, attached to the protein?
>>>
>>> Thanks for your help!
>>>
>>> Best,
>>> Christian
>>>
>>> --
>>> *Christian Seitz*
>>> PhD, Biochemistry & Biophysics | UCSD
>>> Postdoc, Computer Science | UChicago
>>> cgs...@gm... <cg...@uc...>
>>> [image: www.linkedin.com/in/christianseitz21]
>>> <http://www.linkedin.com/in/christianseitz21>
>>> _______________________________________________
>>> GaMD-discuss mailing list
>>> GaM...@li...
>>> https://lists.sourceforge.net/lists/listinfo/gamd-discuss
>>>
>>>
>>>
>>
>> --
>> *Christian Seitz*
>> PhD, Biochemistry & Biophysics | UCSD
>> Postdoc, Computer Science | UChicago
>> cgs...@gm... <cg...@uc...>
>> [image: www.linkedin.com/in/christianseitz21]
>> <http://www.linkedin.com/in/christianseitz21>
>> _______________________________________________
>> GaMD-discuss mailing list
>> GaM...@li...
>> https://lists.sourceforge.net/lists/listinfo/gamd-discuss
>>
>>
>>
>
> --
> *Christian Seitz*
> PhD, Biochemistry & Biophysics | UCSD
> Postdoc, Computer Science | UChicago
> cgs...@gm... <cg...@uc...>
> [image: www.linkedin.com/in/christianseitz21]
> <http://www.linkedin.com/in/christianseitz21>
>
>
>
>
--
*Christian Seitz*
PhD, Biochemistry & Biophysics | UCSD
Postdoc, Computer Science | UChicago
cgs...@gm... <cg...@uc...>
[image: www.linkedin.com/in/christianseitz21]
<http://www.linkedin.com/in/christianseitz21>
|