OK it’s all about the collate_fn() which did not know about namedtuple’s. Modified it to dict, image tensor is OK but the integer sentence arrays are messed/transposed. I think it would be better to just write a collate_fn suitable for the dataset.
Thanks!