Simulating high-intensity proton beams in nonlinear lattices with PyORBIT