Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
3c8adf0c
Commit
3c8adf0c
authored
Oct 31, 2012
by
Peter Eastman
Browse files
OpenCL and CUDA tests are run three times, once for each precision model
parent
6f4ec6b6
Changes
80
Show whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
80 additions
and
61 deletions
+80
-61
platforms/opencl/tests/TestOpenCLRBTorsionForce.cpp
platforms/opencl/tests/TestOpenCLRBTorsionForce.cpp
+5
-3
platforms/opencl/tests/TestOpenCLRandom.cpp
platforms/opencl/tests/TestOpenCLRandom.cpp
+6
-3
platforms/opencl/tests/TestOpenCLSettle.cpp
platforms/opencl/tests/TestOpenCLSettle.cpp
+5
-2
platforms/opencl/tests/TestOpenCLSort.cpp
platforms/opencl/tests/TestOpenCLSort.cpp
+6
-2
platforms/opencl/tests/TestOpenCLVariableLangevinIntegrator.cpp
...rms/opencl/tests/TestOpenCLVariableLangevinIntegrator.cpp
+5
-5
platforms/opencl/tests/TestOpenCLVariableVerletIntegrator.cpp
...forms/opencl/tests/TestOpenCLVariableVerletIntegrator.cpp
+5
-6
platforms/opencl/tests/TestOpenCLVerletIntegrator.cpp
platforms/opencl/tests/TestOpenCLVerletIntegrator.cpp
+5
-6
platforms/opencl/tests/TestOpenCLVirtualSites.cpp
platforms/opencl/tests/TestOpenCLVirtualSites.cpp
+5
-7
plugins/amoeba/platforms/cuda/tests/CMakeLists.txt
plugins/amoeba/platforms/cuda/tests/CMakeLists.txt
+5
-1
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaAngleForce.cpp
.../amoeba/platforms/cuda/tests/TestCudaAmoebaAngleForce.cpp
+3
-2
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaBondForce.cpp
...s/amoeba/platforms/cuda/tests/TestCudaAmoebaBondForce.cpp
+3
-2
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaGeneralizedKirkwoodForce.cpp
...rms/cuda/tests/TestCudaAmoebaGeneralizedKirkwoodForce.cpp
+3
-2
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaInPlaneAngleForce.cpp
.../platforms/cuda/tests/TestCudaAmoebaInPlaneAngleForce.cpp
+3
-2
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaMultipoleForce.cpp
...eba/platforms/cuda/tests/TestCudaAmoebaMultipoleForce.cpp
+3
-2
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaOutOfPlaneBendForce.cpp
...latforms/cuda/tests/TestCudaAmoebaOutOfPlaneBendForce.cpp
+3
-2
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaPiTorsionForce.cpp
...eba/platforms/cuda/tests/TestCudaAmoebaPiTorsionForce.cpp
+3
-2
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaStretchBendForce.cpp
...a/platforms/cuda/tests/TestCudaAmoebaStretchBendForce.cpp
+3
-3
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaTorsionTorsionForce.cpp
...latforms/cuda/tests/TestCudaAmoebaTorsionTorsionForce.cpp
+3
-3
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaVdwForce.cpp
...ns/amoeba/platforms/cuda/tests/TestCudaAmoebaVdwForce.cpp
+3
-3
plugins/amoeba/platforms/cuda/tests/TestCudaWcaDispersionForce.cpp
...moeba/platforms/cuda/tests/TestCudaWcaDispersionForce.cpp
+3
-3
No files found.
platforms/opencl/tests/TestOpenCLRBTorsionForce.cpp
View file @
3c8adf0c
...
...
@@ -46,10 +46,11 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
const
double
TOL
=
1e-5
;
void
testRBTorsions
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
1.0
);
system
.
addParticle
(
1.0
);
...
...
@@ -112,7 +113,6 @@ void testRBTorsions() {
}
void
testParallelComputation
()
{
OpenCLPlatform
platform
;
System
system
;
const
int
numParticles
=
200
;
for
(
int
i
=
0
;
i
<
numParticles
;
i
++
)
...
...
@@ -140,8 +140,10 @@ void testParallelComputation() {
ASSERT_EQUAL_VEC
(
state1
.
getForces
()[
i
],
state2
.
getForces
()[
i
],
1e-5
);
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testRBTorsions
();
testParallelComputation
();
}
...
...
platforms/opencl/tests/TestOpenCLRandom.cpp
View file @
3c8adf0c
...
...
@@ -47,12 +47,14 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
void
testGaussian
()
{
int
numAtoms
=
5000
;
System
system
;
for
(
int
i
=
0
;
i
<
numAtoms
;
i
++
)
system
.
addParticle
(
1.0
);
OpenCLPlatform
::
PlatformData
platformData
(
system
,
""
,
""
,
"single"
);
OpenCLPlatform
::
PlatformData
platformData
(
system
,
""
,
""
,
platform
.
getPropertyDefaultValue
(
"OpenCLPrecision"
)
);
OpenCLContext
&
context
=
*
platformData
.
contexts
[
0
];
context
.
initialize
();
context
.
getIntegrationUtilities
().
initRandomNumberGenerator
(
0
);
...
...
@@ -91,7 +93,6 @@ void testRandomVelocities() {
const
int
numParticles
=
10000
;
const
double
temperture
=
100.0
;
OpenCLPlatform
platform
;
System
system
;
VerletIntegrator
integrator
(
0.01
);
for
(
int
i
=
0
;
i
<
numParticles
;
++
i
)
...
...
@@ -129,8 +130,10 @@ void testRandomVelocities() {
ASSERT_USUALLY_EQUAL_TOL
(
expected
,
ke
,
4
/
sqrt
(
numParticles
));
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testGaussian
();
testRandomVelocities
();
}
...
...
platforms/opencl/tests/TestOpenCLSettle.cpp
View file @
3c8adf0c
...
...
@@ -47,12 +47,13 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
void
testConstraints
()
{
const
int
numMolecules
=
10
;
const
int
numParticles
=
numMolecules
*
3
;
const
int
numConstraints
=
numMolecules
*
3
;
const
double
temp
=
100.0
;
OpenCLPlatform
platform
;
System
system
;
LangevinIntegrator
integrator
(
temp
,
2.0
,
0.001
);
integrator
.
setConstraintTolerance
(
1e-5
);
...
...
@@ -103,8 +104,10 @@ void testConstraints() {
}
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testConstraints
();
}
catch
(
const
exception
&
e
)
{
...
...
platforms/opencl/tests/TestOpenCLSort.cpp
View file @
3c8adf0c
...
...
@@ -46,6 +46,8 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
struct
SortTrait
{
typedef
cl_float
DataType
;
typedef
cl_float
KeyType
;
...
...
@@ -62,7 +64,7 @@ void verifySorting(vector<float> array) {
System
system
;
system
.
addParticle
(
0.0
);
OpenCLPlatform
::
PlatformData
platformData
(
system
,
""
,
""
,
"single"
);
OpenCLPlatform
::
PlatformData
platformData
(
system
,
""
,
""
,
platform
.
getPropertyDefaultValue
(
"OpenCLPrecision"
)
);
OpenCLContext
&
context
=
*
platformData
.
contexts
[
0
];
context
.
initialize
();
OpenCLArray
data
(
context
,
array
.
size
(),
sizeof
(
float
),
"sortData"
);
...
...
@@ -106,8 +108,10 @@ void testLogValues()
verifySorting
(
array
);
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testUniformValues
();
testLogValues
();
}
...
...
platforms/opencl/tests/TestOpenCLVariableLangevinIntegrator.cpp
View file @
3c8adf0c
...
...
@@ -48,10 +48,11 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
const
double
TOL
=
1e-5
;
void
testSingleBond
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
2.0
);
system
.
addParticle
(
2.0
);
...
...
@@ -97,7 +98,6 @@ void testSingleBond() {
void
testTemperature
()
{
const
int
numParticles
=
8
;
const
double
temp
=
100.0
;
OpenCLPlatform
platform
;
System
system
;
VariableLangevinIntegrator
integrator
(
temp
,
2.0
,
1e-4
);
NonbondedForce
*
forceField
=
new
NonbondedForce
();
...
...
@@ -132,7 +132,6 @@ void testTemperature() {
void
testConstraints
()
{
const
int
numParticles
=
8
;
const
double
temp
=
100.0
;
OpenCLPlatform
platform
;
System
system
;
VariableLangevinIntegrator
integrator
(
temp
,
2.0
,
1e-5
);
integrator
.
setConstraintTolerance
(
1e-5
);
...
...
@@ -175,7 +174,6 @@ void testConstraints() {
void
testRandomSeed
()
{
const
int
numParticles
=
8
;
const
double
temp
=
100.0
;
OpenCLPlatform
platform
;
System
system
;
VariableLangevinIntegrator
integrator
(
temp
,
2.0
,
1e-5
);
NonbondedForce
*
forceField
=
new
NonbondedForce
();
...
...
@@ -230,8 +228,10 @@ void testRandomSeed() {
}
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testSingleBond
();
testTemperature
();
testConstraints
();
...
...
platforms/opencl/tests/TestOpenCLVariableVerletIntegrator.cpp
View file @
3c8adf0c
...
...
@@ -48,10 +48,11 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
const
double
TOL
=
1e-5
;
void
testSingleBond
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
2.0
);
system
.
addParticle
(
2.0
);
...
...
@@ -88,8 +89,6 @@ void testSingleBond() {
void
testConstraints
()
{
const
int
numParticles
=
8
;
const
int
numConstraints
=
5
;
const
double
temp
=
100.0
;
OpenCLPlatform
platform
;
System
system
;
VariableVerletIntegrator
integrator
(
1e-5
);
integrator
.
setConstraintTolerance
(
1e-5
);
...
...
@@ -150,8 +149,6 @@ void testConstraints() {
void
testConstrainedClusters
()
{
const
int
numParticles
=
7
;
const
double
temp
=
500.0
;
OpenCLPlatform
platform
;
System
system
;
VariableVerletIntegrator
integrator
(
1e-5
);
integrator
.
setConstraintTolerance
(
1e-5
);
...
...
@@ -213,8 +210,10 @@ void testConstrainedClusters() {
ASSERT
(
context
.
getState
(
State
::
Positions
).
getTime
()
>
0.1
);
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testSingleBond
();
testConstraints
();
testConstrainedClusters
();
...
...
platforms/opencl/tests/TestOpenCLVerletIntegrator.cpp
View file @
3c8adf0c
...
...
@@ -48,10 +48,11 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
const
double
TOL
=
1e-5
;
void
testSingleBond
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
2.0
);
system
.
addParticle
(
2.0
);
...
...
@@ -88,8 +89,6 @@ void testSingleBond() {
void
testConstraints
()
{
const
int
numParticles
=
8
;
const
int
numConstraints
=
5
;
const
double
temp
=
100.0
;
OpenCLPlatform
platform
;
System
system
;
VerletIntegrator
integrator
(
0.001
);
integrator
.
setConstraintTolerance
(
1e-5
);
...
...
@@ -142,8 +141,6 @@ void testConstraints() {
void
testConstrainedClusters
()
{
const
int
numParticles
=
7
;
const
double
temp
=
500.0
;
OpenCLPlatform
platform
;
System
system
;
VerletIntegrator
integrator
(
0.001
);
integrator
.
setConstraintTolerance
(
1e-5
);
...
...
@@ -204,8 +201,10 @@ void testConstrainedClusters() {
}
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testSingleBond
();
testConstraints
();
testConstrainedClusters
();
...
...
platforms/opencl/tests/TestOpenCLVirtualSites.cpp
View file @
3c8adf0c
...
...
@@ -50,11 +50,12 @@
using
namespace
OpenMM
;
using
namespace
std
;
OpenCLPlatform
platform
;
/**
* Check that massless particles are handled correctly.
*/
void
testMasslessParticle
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
0.0
);
system
.
addParticle
(
1.0
);
...
...
@@ -91,7 +92,6 @@ void testMasslessParticle() {
* Test a TwoParticleAverageSite virtual site.
*/
void
testTwoParticleAverage
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
1.0
);
system
.
addParticle
(
1.0
);
...
...
@@ -128,7 +128,6 @@ void testTwoParticleAverage() {
* Test a ThreeParticleAverageSite virtual site.
*/
void
testThreeParticleAverage
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
1.0
);
system
.
addParticle
(
1.0
);
...
...
@@ -170,7 +169,6 @@ void testThreeParticleAverage() {
* Test an OutOfPlaneSite virtual site.
*/
void
testOutOfPlane
()
{
OpenCLPlatform
platform
;
System
system
;
system
.
addParticle
(
1.0
);
system
.
addParticle
(
1.0
);
...
...
@@ -220,7 +218,6 @@ void testOutOfPlane() {
* when using virtual sites.
*/
void
testConservationLaws
()
{
OpenCLPlatform
platform
;
System
system
;
NonbondedForce
*
forceField
=
new
NonbondedForce
();
system
.
addForce
(
forceField
);
...
...
@@ -329,7 +326,6 @@ void testConservationLaws() {
void
testReordering
()
{
const
double
cutoff
=
2.0
;
const
double
boxSize
=
20.0
;
OpenCLPlatform
platform
;
System
system
;
NonbondedForce
*
nonbonded
=
new
NonbondedForce
();
system
.
addForce
(
nonbonded
);
...
...
@@ -430,8 +426,10 @@ void testReordering() {
}
}
int
main
()
{
int
main
(
int
argc
,
char
*
argv
[]
)
{
try
{
if
(
argc
>
1
)
platform
.
setPropertyDefaultValue
(
"OpenCLPrecision"
,
string
(
argv
[
1
]));
testMasslessParticle
();
testTwoParticleAverage
();
testThreeParticleAverage
();
...
...
plugins/amoeba/platforms/cuda/tests/CMakeLists.txt
View file @
3c8adf0c
...
...
@@ -14,6 +14,10 @@ FOREACH(TEST_PROG ${TEST_PROGS})
# Link with shared library
ADD_EXECUTABLE
(
${
TEST_ROOT
}
${
TEST_PROG
}
)
TARGET_LINK_LIBRARIES
(
${
TEST_ROOT
}
${
SHARED_AMOEBA_TARGET
}
${
SHARED_TARGET
}
)
ADD_TEST
(
${
TEST_ROOT
}
${
EXECUTABLE_OUTPUT_PATH
}
/
${
TEST_ROOT
}
)
ADD_TEST
(
${
TEST_ROOT
}
Single
${
EXECUTABLE_OUTPUT_PATH
}
/
${
TEST_ROOT
}
single
)
IF
(
OPENMM_BUILD_CUDA_DOUBLE_PRECISION_TESTS
)
ADD_TEST
(
${
TEST_ROOT
}
Mixed
${
EXECUTABLE_OUTPUT_PATH
}
/
${
TEST_ROOT
}
mixed
)
ADD_TEST
(
${
TEST_ROOT
}
Double
${
EXECUTABLE_OUTPUT_PATH
}
/
${
TEST_ROOT
}
double
)
ENDIF
(
OPENMM_BUILD_CUDA_DOUBLE_PRECISION_TESTS
)
ENDFOREACH
(
TEST_PROG
${
TEST_PROGS
}
)
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaAngleForce.cpp
View file @
3c8adf0c
...
...
@@ -302,11 +302,12 @@ void testOneAngle( FILE* log ) {
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaAngleForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testOneAngle
(
log
);
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaBondForce.cpp
View file @
3c8adf0c
...
...
@@ -206,11 +206,12 @@ void testTwoBond( FILE* log ) {
compareWithExpectedForceAndEnergy
(
context
,
*
amoebaBondForce
,
TOL
,
"testTwoBond"
,
log
);
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaBondForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testTwoBond
(
log
);
}
catch
(
const
std
::
exception
&
e
)
{
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaGeneralizedKirkwoodForce.cpp
View file @
3c8adf0c
...
...
@@ -8450,11 +8450,12 @@ static void testGeneralizedKirkwoodVillinMutualPolarization( FILE* log ) {
compareForceNormsEnergy( testName, expectedEnergy, energy, expectedForces, forces, tolerance, log );
}
int main( int numberOfArguments, char* argv[] ) {
int main(int argc, char* argv[]) {
try {
std::cout << "TestCudaAmoebaGeneralizedKirkwoodForce running test..." << std::endl;
registerAmoebaCudaKernelFactories();
if (argc > 1)
Platform::getPlatformByName("CUDA").setPropertyDefaultValue("CudaPrecision", std::string(argv[1]));
FILE* log = NULL;
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaInPlaneAngleForce.cpp
View file @
3c8adf0c
...
...
@@ -379,11 +379,12 @@ void testOneAngle( FILE* log ) {
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaInPlaneAngleForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testOneAngle
(
NULL
);
}
catch
(
const
std
::
exception
&
e
)
{
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaMultipoleForce.cpp
View file @
3c8adf0c
...
...
@@ -2843,11 +2843,12 @@ static void testMultipoleGridPotential( FILE* log ) {
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaMultipoleForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaOutOfPlaneBendForce.cpp
View file @
3c8adf0c
...
...
@@ -508,11 +508,12 @@ void testOneOutOfPlaneBend2( FILE* log, int setId ) {
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaOutOfPlaneBendForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testOneOutOfPlaneBend
(
log
);
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaPiTorsionForce.cpp
View file @
3c8adf0c
...
...
@@ -305,11 +305,12 @@ void testOnePiTorsion( FILE* log ) {
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaPiTorsionForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testOnePiTorsion
(
log
);
}
catch
(
const
std
::
exception
&
e
)
{
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaStretchBendForce.cpp
View file @
3c8adf0c
...
...
@@ -290,12 +290,12 @@ void testOneStretchBend( FILE* log ) {
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaStretchBendForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testOneStretchBend
(
log
);
}
catch
(
const
std
::
exception
&
e
)
{
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaTorsionTorsionForce.cpp
View file @
3c8adf0c
...
...
@@ -2681,12 +2681,12 @@ void testTorsionTorsion( FILE* log, int systemId ) {
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaTorsionTorsionForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testTorsionTorsion
(
log
,
1
);
}
catch
(
const
std
::
exception
&
e
)
{
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaVdwForce.cpp
View file @
3c8adf0c
...
...
@@ -1952,12 +1952,12 @@ void testVdwWater( int includeVdwDispersionCorrection, FILE* log ) {
}
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaVdwForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
testVdw
(
log
);
...
...
plugins/amoeba/platforms/cuda/tests/TestCudaWcaDispersionForce.cpp
View file @
3c8adf0c
...
...
@@ -162,12 +162,12 @@ void testWcaDispersionAmmonia( FILE* log ) {
compareForcesEnergy
(
testName
,
expectedEnergy
,
energy
,
expectedForces
,
forces
,
tolerance
,
log
);
}
int
main
(
int
numberOfArguments
,
char
*
argv
[]
)
{
int
main
(
int
argc
,
char
*
argv
[])
{
try
{
std
::
cout
<<
"TestCudaAmoebaWcaDispersionForce running test..."
<<
std
::
endl
;
registerAmoebaCudaKernelFactories
();
if
(
argc
>
1
)
Platform
::
getPlatformByName
(
"CUDA"
).
setPropertyDefaultValue
(
"CudaPrecision"
,
std
::
string
(
argv
[
1
]));
FILE
*
log
=
NULL
;
// test Wca dispersion force using two ammonia molecules
...
...
Prev
1
2
3
4
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment