Hello OpenLB community,
I changed the config file to gpu_only and tried to run some of the examples. While compiling, some warnings started to appear however the simulation ran. But for any of the particles example file it stated that there is an error and it can not be ran. Is the resolved particle system not adapted to the be run by a gpu?
The error goes as:
../../../src/functors/lattice/latticeMomentumExchangeForce.hh(292): error: no instance of function template “olb::particles::resolved::momentumExchangeAtSurfaceLocation” matches the argument list
argument types are: (T *, olb::Vector<T, 2U>, const int *, const olb::BlockGeometry<T, 2U>, olb::BlockLattice<T, DESCRIPTOR>, const olb::UnitConverter<T, DESCRIPTOR>, olb::particles::Particle<T, PARTICLETYPE>)
if ( particles::resolved::momentumExchangeAtSurfaceLocation(tmpForce.data(),
/////
My system uses an RTX 3060 and the following config file is used:
# Example build config for OpenLB using CUDA on single GPU systems
#
# Tested using CUDA 11.4
#
# Usage:
# – Copy this file to OpenLB root as config.mk
# – Adjust CUDA_ARCH to match your specifc GPU
# – Run make clean; make
# – Switch to example directory, e.g. examples/laminar/cavity3dBenchmark
# – Run make
# – Start the simulation using ./cavity3d
CXX := nvcc
CC := nvcc
CXXFLAGS := -O3
CXXFLAGS += -std=c++17 –forward-unknown-to-host-compiler
PARALLEL_MODE := NONE
PLATFORMS := CPU_SISD GPU_CUDA
# for e.g. RTX 30* (Ampere), see table in rules.mk
for other options
CUDA_ARCH := 86
FLOATING_POINT_TYPE := float
USE_EMBEDDED_DEPENDENCIES := ON
I have implemented CUDA and its toolkit according to the user guide.