IRay start delay
marble
Posts: 7,500
I have just migrated my DAZ Studio+Content to a new PC with an Iray capable GPU, so I'm in the process of learning more about it. For example, I've discovered Preview mode and Interactive rendering which are very useful for getting an idea of how the final render will look. However, I have noticed that, no matter how small the scene, there is a delay for each new render. In my test scenes so far, this has been taking upwards of 40 seconds before I see anything in the render window. Preview mode in the Viewport seems to overcome this somehow and constantly updates the render on the fly.
The delay is acceptable for a still image but I was wondering about animation. Seems to me that Interactive Mode is ideal for animation but it still has the initial delay which prompts me to ask how people can claim times like 10 seconds a frame for animations?

Comments
There's a certain amount of work to be done before the render can start - converting any surfaces using 3Delight shaders to the basic Iray shader, any texture compression (thresholds set in the Advanced tab of Render Settings), and putting the scene into the GPU memory. You can't do much about the last, but you can reduce the fist two by making sure everything uses the Iray sahder and by adjustign map sizes manually.
Thanks Richard - I thought that would be the case but it still doesn't answer how people can get such short render times for animations. Does it handle animation renders differently? If so, how do we select that option? From what I can see, 10 or 12 seconds is impossible if you include the set-up time.
It seems to me that for an animation all this work is done for the first frame. All the textures will have been handled as well as the shaders..no need to redo them.
Another thread I found had the following conversation:
And the reply was ...
I'm not quite sure what that means. Also, if the initial render is left open somehow, would that consume VRAM, effectively restricting the size of the animated frame?
Yes...it is held in memory and yes each open window will 'reserve' memory. But what is the alternative...recompiling for each frame?
I wondered whether the same "modules" loaded in memory could be shared between renders. Bear in mind I have no programming experience so I don't know if what I'm suggesting is just plain silly.
Congrats on the machine. The bigger the scene the bigger the delay. In bigger scenes preview can be a pain, but still useful. At times rendering can take as long as lux but faster overall.
Hi Bob.
Yeah, I stayed with Reality/Lux as long as I could but, in the end, so much was happening that was more straightforward using IRay that I had to either get a PC or find another hobby. I was buying products that were just not rendering very well in Lux so I was spending so much time adjusting materials and lights that it wasn't worth the effort. Paolo is a very clever man and he has done an incredible job with Reality but he is one man against a joint NVidia/DAZ development team with all the vendors creating materials for IRay.
Maybe I will try GPU renders in Luxrender as a comparison but, right now, I want to learn IRay as quickly as possible.
Yes, that delay is inevitable, but still a little taxing to your patience (especially if you are as impatient as I am), but I find the overall timesaving of having the Iray workspace draw mode is huge compared to having to do full renders every time (as with Reality/Lux). Also when changing materials on objects the re-rendering this triggers takes much less time than loading the scene the first time. And recovery when making changes to the dome (e.g. rotation) seem to take almost no time.
With my long experience with Luxrender I found that I got the hang of Iray pretty quickly and I still use the same habits of lighting that I used with Lux and they work just as well.
It was the opposite for some reason it took me a while to get iray one of the big factors is unlike Reality / lux the influence with lighting and skin.That dammed render time limit took me a while to figure out how to let it run as long as I want to. Having figured that out, in some cases they can take as long as lux. God forbid I forget to adjust one of the settings I only come back from doing something to find the render had stopped. The good thing is one can then adjust said setting and resume render.If one wants to see if a render is complete enough one can save the render from DS and if not completed to satisfaction resume it from the render window. It is not necessary to convert ALL metrials to iray uber in many cases materials will convert well as is.. Having said that using shaders is alot of fun.. http://fav.me/d9zx2h5
There is a way to significantly reduce the time the figures appear as grey when using preview mode, but I can not find the thread that explained what u had to do, and I am away from my computer to look what settings I changed. I am pretty sure it was in the draw settings tab, you can select nvidia iray here and there are a number of settings to tweak. I know after I had done it preview became much more useful to me.
Whether this will help animations though I am not sure.
Marble, which GPU did you select? I remember you saying you had tried out GTX970 in the past.
MEC4D did a video showing how leaving the preview window open eliminates the startup delay for all frames of the animation. Take a look: https://www.youtube.com/watch?v=a-CarAgi_ns
Hi Havos.
I'm not too concerned about the "grey time" because, once the textures appear, they keep updating quite quickly in preview mode. I'm not really ready for animations yet but I did wonder about IRay having to run through the setup for every render and whether it perhaps cached any of the pre-loaded materials, etc.
I went, once again, for the GTX970 and have to say that it seems orders of magnitude faster than the previous one. Now that might be explained by the fact that I've learned a bit since then or that the whole PC is brand new, including a Skylake i7 and a motherboard which allows me to connect the display to the Skylake internal graphics and leave my GTX970 for Iray. Also, I didn't know about configuring Draw/Preview/Interactive until now. The new DAZ video tutorials were a help with that.
I still haven't tested with a crowded scene - maybe I'm too nervous about being disappointed after spending too much money I can't afford.
Thanks - I just tried this and it does work - having the preview in the Viewport (I set preview and Render to Photoreal just for the test) does indeed bypass the startup delay.
Just wish I had a couple of Titan X cards like MEC4D is showing in the video!
I am assuming that your old PC has less memory than your new one, and that is likely the reason your initial tests with the GPU was unsatisfactory. As you know DS eats a lot of memory, and so does iRay, so any box with too little memory will suffer significant lag. I have 32 GB and for me my GTX 970 roughly cuts render times to a tenth of those using CPU alone. Hopefully you are seeing a similar speed up.
Actually I had addded more memory on the old one too - 16GB which is what I have on the new one. Still, I'm sure the speed of the memory has improved - that was six year old technology. I'll have a better idea when I create a more typical scene. So far I've been rendering single figures just to get familiar with IRay. However, a single figure using Reality would take about 6 minutes to produce a fairly clean image and, from what I can see so far, it is taking IRay about 2 minutes (quicker without the initial setup period we are discussing in this thread). For now, I'm ignoring convergence percentage or iteration numbers and just looking at the image.
One thing I've seen that kills my Iray render speeds is anything with SubD set to more than 2 levels. Kills it dead. Well, not dead. It still renders but slower than going to art school and learning how to just paint it myself. Also I've been using Iray for a while on a two year old laptop (high-ish end at the time, now not so much) and Iray struggles with enclosed geometry (i.e. light having to bounce around a lot). Really slow. So I try to make sets with only two walls and a floor or use a background image like a studio backdrop might be in order to work around it.
From the old days waaaay before Iray, when putting more than one model in a scene would make my system crawl, I keep the body count down to two typically, or use old low res figures for background, etc. Yesterday I tried three G3F in the same scene and it killed Iray. GPU couldnt' handle it at all (too many textures / memory to load) so it went to CPU and took about 6 or 7 minutes just going through all that pre-render stuff, then the render was glacially slow. So my limit is two current gen figures in a render. Your rig sounds way better though so why not just keep popping in figures until you can't stand the speed impact?
Anyway geometry density/resolution, light bounces, and quantity/size of textures all contribute to my render speed problems.
I'm used to Luxrender and, for that, anything with HD had to have the SubD level at 3 at least. Is it the same with IRay (I can't check at the moment)? I have Decimator but have never found a use for it - perhaps I could make Low Poly versions of my characters for when they are not in close-up.
I try to buy room sets with visibility switches for each wall and ceiling but many of the latest products are box containers with no individual wall settings or movement.
If a room has no wall visibility settings you can use the geometry editor to select the wall polys and assign them to a new surface, then make that surface invisible.
I render all my characters at 3 levels of subD (unless they are background characters as there is no point in using HD on them) because I always use HD features and I have to say I don't particularly notice my renders slowing down as a result. What takes the time is heavy SSS and enclosed architecture. Basically, if I can't make good use of HDRI environment or unobstructed lighting with minimal bounce I won't use architectural sets other than as background. It's fine for the sort of thing I do—a floor and one wall is all I really need. It's kind of the equivalent of using stage or movie set lighting rather than interior location lighting. Maybe it's because I just don't know how to do interior lighting as I've seen some great renders done in that way (although I don't know how long they took to render!). I had to be very patient in the days when I used Luxrender without significant GPU support, but I resented it. I've lost a lot of that patience now I have a good GPU and Iray (to be fair, no dount renders with Lux will benefit greatly from that, but I feel I've now been spoilt by using Iray).
i don't think there is any need to decimate background characters (unless you are talking crowds), just don't use SSS and use base if they look OK. Genesis 1 is hardly crazy high poly at base resolution.
Lux is faster then before. In some cases (not most) iray can take just as long. I have 2 good machines 32G tower with GTX980 and ROG asus 24G laptop with 980M. The only thing with lux now if I use CPU acc no boost if using more then 1 light then I see patterns on the skin. There is apprently ways to line up lights so you dont see them I cant be bothered when iray works fine as is... I am curious to see what lux 1.6 will bring. It is in the RC stage but Paolo does not recommend using it until he has it ready with future version of Reality..I did go back using it for my own stuff but now working on commission projects so using iray...
@Hiro Protagonist : I agree with your points - you echo my own experience with Luxrender. I can't say that I noticed a huge slow down at +3 SubD but I also left it at +1 for chracters at a distance. I had big problems with SSS in Lux so I always turned it off. Most of my indoor scenes were missing walls out of shot because I read that Luxrender doesn't calculate rays going to infinity.
I also read somewhere (damn, I ought to bookmark these things) that it is possible to use the IRay dome and HDR indoors by reducing the dome size to fit inside the room (+/- 2 Metres) and turning off Draw Dome. I need some time to try these tricks of the trade.
@Bobvan : You are right - having a good GPU doesn't preclude using Luxrender and if 1.6 brings something special, it is good to have Reality in the toolbox. My gripe with Reality is not so much speed but material conversion. Now that vendors concentrate on IRay, it is getting more difficult to get a plausible conversion to Lux materials. And saving material presets in Reality sucks big time. Then there's the problems with SSS, displacement and geografts - too much hassle.
You can have just little viewport open not need big so your scene is preloaded to the cards, not doing it will load the full scene each time to the card for each frame over and over again and process all data and not just the updates or changes in the frames, if you render animations it will waste a lot of hours if you not do so as all light and even objects that did not changed will be processed again .
Also if your all materials are not converted to Iray it will take even longer as iray need to convert it from 3DL and estimate what it suppose to be giving you not always desired final result and even wrong lighting condition
For people that have very limited memory to render with GPU, the best idea here is to setup the scene in viewport save it, start render , cancel but not close, remove the scene from viewport let say load empty scene and after that click resume on the render, it will clean up the taken memory for the viewport scene from the card . Sometimes I render using 3 x DS at the same time this way so 3 renders are produced if one of them finish faster the extra power goes to the next still rendered frames . That is my fake Batch processing lol
That are my old tricks from the time when I was rendered with a slower GTX 760 2GB card , see the open Iray viewport as a bridge to your GPU , once it is closed everything need to be re-loaded to your card memory and calculated once again even if you make just a slight changes to materials or scene , so keep it open so all changes happening in real time that why AUX viewport is the best choice here as you can keep it minimal in size and have your regular viewport as big as you need
Thanks again - some very handy tips there. I have tried with the Aux Viewport but I might be missing some tricks. I need to experiment some more with Aux Viewport and Draw Styles because I'm not sure when and why the IRay render settings influence the Viewport Iray Draw Style. It seems to me that if I set the Viewport to Interactive and then set the Render to Photoreal, that forces the Viewport into Photoreal mode.
As I say, I need to experiment more to confirm this.
Anyone know what Inactive Viewport Delay does in the Draw Style IRay settings?
Good question as it does nothing under photoreal mode , beside I can't even switch to interactive mode to test as it crash my Nvidia display driver each time I try
I'm having a worrying amount of crashes too - but not so specific that I can say what is causing them. It seems to be related to DAZ Studio not releasing memory (or VRAM) when shaders or materials or poses are changed, added or deleted.
I have it all the time , before even iray but now I always wait a little bit after changing things before I move or do anything and that is for sure not vram related , I am getting always message nonresponding or something like that , I can run Interactive using CPU but the moment I switch to GPU it crash my graphic driver and DS closing offering me to process thing via Visual Studio what is really weird as no issues with Photoreal mode
I've just moved from Mac to PC and I have to say that I had forgotten how often DS crashed on Windows. I rarely had a crash on the Mac but then other things have forced me back to the PC.
By the way, I downloaded the latest NVidia drivers today and DS would not even start. I had to back out to older drivers.
No problem with the latest driver here , I never use express installation it can mess up pretty well everything .