mlr3
mlr3 copied to clipboard
feat(Learner): Allow for additional input checks on task
By adding this feature, it is possible for learner's to perform custom compatibility checks. This is e.g. needed in torch, where we have a "tensor column", where the tensor can have different shapes. To verify that the tensor shapes fits together with the neural network, we want to perform input checks before calling into train, as incompatability is a user error and should not trigger the fallback learner
- [ ] In case this is accepted, add it do the "Extending" tutorial from mlr3extralearners.
We can alternatively allow for something like this, by introducing a error condition such as NoFallback that is then handled by learner_train()