you're welcome... one thing you can do to deal with performance issue in pygame when it come to pixel manipulation or blitting so many things at once is as follow:
create a small display surface like (320, 240), blit everything on it (sprites must be tiny) then scal it to the screen size like (640, 420) then blit it on screen. that should resolve performance problems in raycasting and pseudo 3D engines, and I think this is how programmers dealed with it in the past when they have limited hardware resources.