I don’t know if it’s correctly implemented - you’ll need to create tests to convince yourself of that.
RandTransform looks fine. Not sure what you’re passing as_item=True. Do you need that?
I don’t know exactly what you’re asking about TypeDispatch. What do you want to do? What have you tried? What happened when you tried? Please provide code for anything that didn’t work the way you hoped, as appropriate.
To make GPU transforms work on items or batches you need to use broadcasting carefully. There’s nothing fastai specific about that. Using ellipses, e.g.
t[...,c,x,y], can help. Otherwise, just create separate versions for each with different names.
You should use a profiler to see where the time is being spent.