Can't make MixUp work

At the end of Chapter 14 it is suggested to try training the ResNet with MixUp.

l = Learner(dls, rn, loss_func=nn.CrossEntropyLoss(), metrics=accuracy, cbs=MixUp()).to_fp16()
l.fit_one_cycle(100, 3e-3)

Afaik using the library all that is needed is to add the cbs=MixUp() part. However, this error occurs:

RuntimeError: Exception occured in MixUp when calling event before_batch:
expected dtype long int for weight but got dtype float

I found these 2 issues, but couldn’t solve my problem:
mixup crashing lr_find · Issue #2233 · fastai/fastai · GitHub
Mixup Errors · Issue #3183 · fastai/fastai · GitHub