There is still irritation from a model taking a long time to open for the first time (sequential or NSC).
I often save an NSC model with multiple analysis/graphics windows (e.g. Detector Viewers) for different 'views,' and although I have both
(1) unchecked 'Auto Apply' in Settings: Project Preferences: General dialog, AND
(2) checked 'Show Options First' under the Settings: Project Preferences: Graphics dialog for this model,
upon opening, OpticStudio STILL apparently does a Ray Trace and long recomputation of all graphics windows before I can do anything. And there is no visual feedback of progress, just a 'warning chime' if I try to open a menu, etc.
See Angel Morales's posts on Auto Apply, and Sandrine Auriol's posts on Show Options First in this other thread:
https://my.zemax.com/en-US/forum/threads/3f09e379-46ed-ea11-a817-000d3a329613#
So is there some way to default to opening a large model WITHOUT running all analyses upon opening? Or at least give some display showing how long it might take before one can edit the model?
-- Greg
Hey Greg,
It shouldn't be doing a ray trace on open. I just opened Zemax\Samples\Non-sequential\Miscellaneous\Digital_projector_flys_eye_homogenizer.zmx and got the expected behavior. It loads all the saved data from file and then renders the windows, as expected.
Do you have a merit function that traces NSC rays? If so, make sure it is closed and that no open window is referencing it, otherwise that WILL cause a recalculation. Also, check this setting in Project Preferences:
That will trigger a merit function recalculation (of course) and a ray trace if you have an NSTR operand in the MF.
Aha! Another mysterious check-box!
Thanks, Mark, you hit the nail on the head! And so quickly! Without seeing my file!
I tried it and un-checking 'Update Merit Function On Load' took loading from about 79 s (updating merit function upon load) down to about 17 s (to open and restore about 6 Detector Viewer windows, but indeed no ray trace is being done to update the detectors...I had two detector viewers that displayed 'Ray Trace Has Not Been Run').
The culprit was the Merit Function Editor, all right. I thought it wasn't being used. It is not referred to by any other windows. But I had created it with NSTR and NSDD in order to make Universal Plot 1D, and it was lurking there to be Updated On Load. Doesn't matter if the Merit Function Editor window is closed or open.
[Speaking of which, an updated KnowledgeBase Article on how to use Universal Plots like that in NSC mode would be helpful; Sanjay Gangadhara's KA-01448 'How to use the NSDD operand with the Universal Plot' is a great start, but really could use an additional screen shot of the Merit Function Editor used for his example plots, along with an NSC Editor shot showing which detectors are in place for NSDD.]
Under Project Preferences: General, I also played with unchecking 'Use Session Files' and 'Include Calculated Data in Session.' When opening the NSC Editor only (no other graphics windows, shaded model, detector viewers, or Merit Function Editor), the model loads ~instantaneously.
I also newly learned that Project Preferences really applies to all new files, but that to alter e.g. 'Include Calculated Data in Session File,' the box under System Explorer: Advanced needs to be un-checked to apply to the open file at hand.
BTW, I noticed that there is no 'Close File' menu item under File. So I went back and forth between New and Open, which I figured out I could do instead of shutting down and restarting OpticStudio just to get a fresh file opening situationl.
Given settings complexity, I almost think it could be useful to have a 'Profiles' or 'Templates' function that saves these complicated bunches of settings (configurations? ZDA and CFG files?) as 'templates' for new files of a certain type, perhaps more importantly for multi-user environments to share settings for things they do frequently. Or maybe people just do this already with no specially-named OpticStudio feature.
-- Greg
P.S. What editor did you use to annotate your screen shot with the pretty numbers in red circles with shadows?
Hey Greg,
I'm glad that worked. The fewer things you do on load of course, the faster load will be. The OS default behavior is to reopen the file exactly as it was when saved. You can save the Project Preferences (see the save and Load buttons on the dialog) and they expectation is that the user will use this for different clients (especially the Folders sections there) or for different users. Project Preferences are loaded separately to the file.
I use Snagit from Techsmith for screen capture. It's a really good, solid, reliable screen capture and recording tool.
- M