The problem is caused when a picture is erased it holds an assoicated "picture" object in memory as long as you stay on the same scene. Every time that picture object comes up, it creates a NEW blank bitmap, every frame, basically if you want it to lag, create a lot of blank pictures when they get garbage collected, it lags. Each erased picture creates a single 32x32 blank bitmap to associate itself with, every frame, same with any picture shown as (none). Since the lag is caused by garbage collection, which is basically uncontrollabe with Ruby.
The reason why it constantly creates new blank pictures is because the base scripts check for the picture name. And if it's "" (aka no picture name), it keeps creating. When a picture is erased, it sets to ""
This script clears Pictures that you already disposed to avoid permanent lag.