HF RL Explorer

Fixes 8697 GPU memory leak by checking both image and label tensors for CUDA device

Fixes 8697 GPU memory leak by checking both image and label tensors for CUDA device: a task in life-science-SWE1.0 (Harbor dataset). Title: Fixes 8697 GPU memory leak by checking both image and label tensors for CUDA device

The task

**Title:** Fixes #8697 GPU memory leak by checking both image and label tensors for CUDA device

Part of scalingX/life-science-SWE1.0.