Beer glass scene creation
This course contains a little bit of everything with modeling, UVing, texturing and dynamics in Maya, as well as compositing multilayered EXR's in Photoshop.
# 1 03-12-2011 , 10:42 PM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520

What happened to the Mental Ray?

It keeps saying it's running out of memory in certain views of a scene.
This is what I get:


mental ray for Maya 2012
mental ray: version 3.9.1.36, Feb 2 2011, revision 138829
initMPS with licenseOption 0
mental ray: got 8 satellite CPUs.
MSG 0.3 error 011105: cannot start thread 6: Not enough storage is available to process this command.
MSG 0.3 error 011105: cannot start thread 7: Not enough storage is available to process this command.
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
mental ray: out of memory
MEM 0.4 fatal 031008: can't allocate 5242880 bytes.
MEM 0.4 fatal 031008: can't allocate 5242880 bytes.

Is there any way to fix this?

# 2 03-12-2011 , 11:39 PM
NextDesign's Avatar
Technical Director
Join Date: Feb 2004
Posts: 2,988
5242880 bytes = ~5 megabytes

Take a look at your task manager when running the render. Is all of your memory being eaten up? If yes, then you'll need to change some things in your scene. Either that, or buy more memory.


Imagination is more important than knowledge.
# 3 03-12-2011 , 11:47 PM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520

5242880 bytes = ~5 megabytes

Take a look at your task manager when running the render. Is all of your memory being eaten up? If yes, then you'll need to change some things in your scene. Either that, or buy more memory.

It seems like this setting is useful:
Export objects on demand and allocate on Heap.
With those two the render seems to be running faster (even though it says it will be slower).
I couldn't check when the crashes happened, but with these settings it doesn't exceed 2.18 gb (out of 4)
3rd picture shows what might be the problem: My scene has these planets far away from the grid and 2 of the objects Sun and Jupiter are slowing down the movement in viewport when both are in the same view (picture 4).

So far it doesn't crash anymore. But I'm still worried about the viewport slight lag.

Attached Thumbnails
Attached Images

Last edited by SilverFeather; 03-12-2011 at 11:53 PM.
# 4 04-12-2011 , 12:31 AM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520
Further tests show that the crashes happen only if I try to render from a view where the transparent ring overlaps the Sun. I can't figure out why though. It's the only angle that crashes the scene even with the "Allocate on Heap".
Also, the RAM isn't even used up halfway when the crash happens.

I can make it crash only from that angle and this is what happens when I render halfway.

I'll try to export stuff separately, maybe the importing had something to do with the problems.
Or the textures.
The entire file has reached 30 mb.

Attached Thumbnails

Last edited by SilverFeather; 04-12-2011 at 01:27 AM.
# 5 04-12-2011 , 01:06 PM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520
Still can't figure out what exactly the problem is.
Tried reducing texture size, still crashes when I render from that angle.
Made a new camera... still crashes when viewing that angle.

What I'm suspecting now is the transparent glowing Torus around the planet, but deleting it doesn't really stop the lag in the viewport.

Seems reducing the polygon numbers on the spheres fixes it (I hope it stays this way). I've smoothed all of the spheres to appear rounder, maybe that's what caused the problems.
Yeah, it fixed it. The Reduce poly tool is very useful for this problem. Seems I have to either:
a) Keep the scene limited to a certain amount of polys
or
b) Make sure that the camera only has to render a certain amount of polys, thus some views will not be rendered if too many polys are in the same image.


Last edited by SilverFeather; 04-12-2011 at 03:46 PM.
# 6 06-12-2011 , 05:29 AM
NextDesign's Avatar
Technical Director
Join Date: Feb 2004
Posts: 2,988
That doesn't seem right. Take a look at this:

Troubleshooting mental ray Rendering on Maya - YouTube
If you have the time, watch the full thing. If you just want to see what I'm specifically pointing to, go to 22 minutes and 58 seconds. Follow those diagnostics, and see if it still crashes.


Imagination is more important than knowledge.
# 7 06-12-2011 , 11:49 AM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520

That doesn't seem right. Take a look at this:

Troubleshooting mental ray Rendering on Maya - YouTube
If you have the time, watch the full thing. If you just want to see what I'm specifically pointing to, go to 22 minutes and 58 seconds. Follow those diagnostics, and see if it still crashes.

Thank you but I've already figured what happened: I exceeded the poly numbers (spheres were double-smoothed and my scene was HUGE). The fix was to just reduce polys on some of the spheres. My scene contains a whole solar system (minus a few dwarf planets and + a few other stars in the distance, the grid is so small now...).

Now I'm trying to animate it but found out that MR doesn't have the convenient .avi option -_- Now I either have to import 1 image at a time to make a movie in Corel Photo-paint (because bulk import reverses the image order, don't know why) or find some other program that acts like Corel and does bulk import in the correct order + has frame control and export to .avi.

# 8 06-12-2011 , 12:01 PM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520
Here's what it looks like.
Zoomed in on 2nd pic.

Attached Thumbnails
# 9 06-12-2011 , 02:40 PM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520

//================================================== ===
Maya Crash Report
//================================================== ===

Exception code: E06D7363:
Fault address: 7C812AFB in C:\WINXP\system32\kernel32.dll
0001:00011AFB Logical offset (see .map file for location)

Registers:
EAX:386F1900
EBX:00000000
ECX:00000000
EDX:386F19AC
ESI:386F1988
EDI:10F5C110
CS:EIP:001B:7C812AFB
SS:ESP:0023:386F18FC EBP:386F1950
DS:0023 ES:0023 FS:003B GS:0000
Flags:00000206

Call stack:
(0) section:offset Address Frame
0001:00011AFB 0x7C812AFB 0x00000000
Module: C:\WINXP\system32\kernel32.dll (-exported-)
Location: RaiseException + 0x52 bytes
Decl: RaiseException
(1) section:offset Address Frame
0001:0005CF60 0x7857DF60 0x00000000
Module: C:\WINXP\WinSxS\x86_Microsoft.VC90.CRT_1fc8b3b9a1e 18e3b_9.0.30729.6161_x-ww_31a54e43\MSVCR90.dll (-exported-)
Location: _CxxThrowException + 0x48 bytes
Decl: _CxxThrowException
(2) section:offset Address Frame
0001:000AB196 0x10F5C196 0x00000000
Module: C:\Program Files\Autodesk\Maya2012\bin\plug-ins\Mayatomr.mll (-exported-)
(3) section:offset Address Frame
0001:002CDAE3 0x1117EAE3 0x00000000
Module: C:\Program Files\Autodesk\Maya2012\bin\plug-ins\Mayatomr.mll (-exported-)
Location: mi_link_file_add + 0x7A33 bytes
Decl: mi_link_file_add
Next frame pointer is missing - is /Oy turned on in this module?

//crash file = C:\DOCUME~1\DETONA~1\LOCALS~1\Temp\MayaCrashLog111 206.1620.log
//version = 2011.03.11.0818
//cut = Fri 03/11/2011, 201103110818

//================================================== ==
//Memory usage:
// 1309.141 Mb Free Memory
// 2048.000 Mb Free Swap
// 728.289 Mb Current
// 149.504 Mb Arrays
// 14.375 Mb MEL
// 25.471 Mb Object Arrays
// 0.938 Mb Data Blocks
// 0.750 Mb NURBS AG
// 0.248 Mb Transforms
// 0.002 Mb arguments
// 0.125 Mb Keys
//================================================== ==

Latest crash report.
Render diagnostics:

MENTAL RAY RENDER DIAGNOSTICS:
Miscellaneous
- Stroke rendering of paint effects is unsupported.
- This scene contains nodes with animated visibility, this requires Optimize Non-animated Display Visibility to be turned off.
- Node Thebe2 has animated visibility.
- Node Amaltea has animated visibility.
- Node Metis has animated visibility.
- Node Adrastea has animated visibility.
- Node Sun2 has animated visibility.
- Node Jupiter2 has animated visibility.
- Node |Io has animated visibility.
- Node Europa has animated visibility.
- Node Ganymede1 has animated visibility.
- Node Callisto1 has animated visibility.
- Node CosmicCam has animated visibility.
- Node polySurface3 has animated visibility.
Performance
- file21 has a resolution of 2048x1024 which may be inefficient.
- If file21 is not a memory mappable file, use imf_copy to convert it to .map format, to improve the performance.
// Warning: 15 warnings, see script editor for details. //



Last edited by SilverFeather; 06-12-2011 at 02:46 PM.
# 10 07-12-2011 , 12:00 AM
NextDesign's Avatar
Technical Director
Join Date: Feb 2004
Posts: 2,988

I've already figured what happened: I exceeded the poly numbers (spheres were double-smoothed and my scene was HUGE).

That still shouldn't CRASH mental ray. It should be slow, as it's writing to the disk (virtual memory); but it should still render.


Imagination is more important than knowledge.
# 11 07-12-2011 , 12:13 AM
SilverFeather's Avatar
Noober than noob
Join Date: Sep 2011
Posts: 520

That still shouldn't CRASH mental ray. It should be slow, as it's writing to the disk (virtual memory); but it should still render.

Idk but that fixed it for single-frame rendering the moment I've reduced polys on spheres and other objects (the moons had the most polys though because they had irregular shape and such).
Then I forgot the Allocate on Heap option on, and the batch renderer began to silently crash.
Good thing I'm out of the woods now.

Posting Rules Forum Rules
You may not post new threads | You may not post replies | You may not post attachments | You may not edit your posts | BB code is On | Smilies are On | [IMG] code is On | HTML code is Off

Similar Threads