If you have the gearbox off and apart, sticking the whole thing in the oven for half an hour will most likely see the bearing fall out by itself.
Replacement would be similar but also put the bearing in the freezer too overnight. It should them tap into hot cases using a suitable size drift against the outer race (a big socket).
Michael Waller is doing a series of videos building a bullet trials bike just now. He goes into detail about the gearbox rebuild in detail. I think this is the one he fits the bearings in. He has a hydraulic press (and if you have one, there's no good reason not to use that) but with a hot case and a cold bearing, it'll probably go most of the way in by itself, won't take much force to drift it the rest of the way.
https://youtu.be/baK5q9hv6Iw
Ignore him fitting the gear clusters, he makes a right hash of it. It's a fairly straightforward job.