Building an Image Data Loader with transforms on the input but not the target

Progress… I set
n_out = 400 * 300

learn_gen = unet_learner(data.dataloaders(main_path), arch, n_out=n_out, wd=wd, norm_type=NormType.Weight, self_attention=True, y_range=y_range, loss_func=loss_gen)

and now I get a learner, but now I’m getting an error when I call learn_gen.fit_one_cycle(2, 1e-2)
The error is

... /opt/conda/lib/python3.7/site-packages/fastai/learner.py in add_cb(self, cb)
    107         cb.learn = self
    108         setattr(self, cb.name, cb)
--> 109         self.cbs.append(cb)
    110         return self
    111 

AttributeError: 'NoneType' object has no attribute 'append'

I saw someone else post this error, and it appeared to be a bug they corrected… but I’m hitting it again. Any help is much appreciated!

Thank you.