Trainer is to be used with PyTorch, so in this case the train_dataset needs to be a PyTorch dataset. TFTrainer would expect a TF dataset. The doc page 21 is a bit unclear (types are right in the signature but too short/wrong in the enumeration). I’ll send a fix to this later today.