If you are rendering a scene with final gather and the lighting flickers, follow these steps:
         
         
            - Enable the  option under the section, Final Gathering Tracing subsection in the Indirect Lighting tab of the Render Settings: mental ray tabs. The  option sets the final gather mode to multiframe. 
               See Final Gathering Modes in the mental ray for Maya reference guide for more information.
                
- Set the Render Mode to render final gather maps using this command: 
               
setAttr mentalrayGlobals.renderMode 3;
 
- Set the scene to render a representative subset of frames or a coarse version of the animation. 
- Set  to  under the  section of the Indirect Lighting tab of the Render Settings: mental ray tabs. 
            
- Set Render Mode to full render using this command: 
               
setAttr mentalrayGlobals.renderMode 0;
 
- Fully render the scene. 
               Note 
                     While this workflow avoids flicker, some parts of the scene may still suffer in quality if an insufficient number of final
                        gather points is found.