Thanks @peter.gaston for reporting the issues.
is_loading API keeps track of the material loading (similar to the progress bar in bottom right corner). However, textures continue to load even after that for sometime which is not tracked by the API. We are working on this to figure out a proper API that takes into account both.
Also, for subsequent randomizations, is_loading will return false as the scene is already fully loaded with materials and textures. Sometime, it takes more than one frame to collect the groundtruth (gt) properly after the scene randomizes. Hence, additional update() calls will solve it.