Why is the data not converted to the CHW format of tensors after the ToTensor() function is used in torch 2.10, but instead remains in the HWC format?

Why is the data not converted to the CHW format of tensors after the ToTensor() function is used in torch 2.10, but instead remains in the HWC format? When I switch to version 2.9.1, the issue is resolved, and the code remains unchanged.

Could you post a minimal and executable code snippet reproducing this behavior, please?