alexandrosstergiou / SoftPool

[ICCV 2021] Code for approximated exponential maximum pooling
MIT License
288 stars 52 forks source link

CUDA error #50

Closed icvplayer closed 2 years ago

icvplayer commented 2 years ago

Hi, If I set force_inplace to False, CUDA will report an error: RuntimeError: CUDA error: an illegal memory access was encountered. cudaCheckError() failed : an illegal memory access was encountered. Could you tell me why please?

alexandrosstergiou commented 2 years ago

Hi @icvplayer ,

This is likely due to your tensor not being contiguous in memory (of the gradients of it). You can wrap the function call around contiguous() calls.