graphics card rtx 3060 ti cuda 11.6. i get cudaErrorIllegalAddress error when i change batch from 1 to 50
typedef bool boxStatus_t;
boxStatus_t * boxStatus{nullptr};
// part of initialization
statusCode
PostprocessingCudaYolo::init(uint8_t batch)
{
try
{
int rs = 0;
rs = cudaMalloc((void **) &(this->boxStatus), YOLO_OUT_SIZE * batch);
if ( rs != cudaSuccess) {
return INIT_ERROR;
}
// part of running pipeline
statusCode
PostprocessingCudaYolo::clearVectors(uint8_t batch)
{
try
{
cudaMemset(this->boxStatus, true , YOLO_OUT_SIZE * batch );
int r = cudaDeviceSynchronize();
if (r != cudaSuccess) {
std::cout << "cudaDeviceSynchronize() return " << r << std::endl;
return CUDA_ERROR;
}
// if batch == 1 OK
// if batch == 50 cudaDeviceSynchronize() return cudaErrorIllegalAddress
// Why??