Community
Maya Forum
Welcome to Autodesk’s Maya Forums. Share your knowledge, ask questions, and explore popular Maya topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Major lag loading reference with lots of instances.

6 REPLIES 6
Reply
Message 1 of 7
RickFalck
1643 Views, 6 Replies

Major lag loading reference with lots of instances.

When trying to load a reference that has a large number of instances (250+) maya takes a very long time (30mins-hour+) to load/ draw all of them, regardless of the complexity of the referenced object.

 

We typically unload (uncheck in reference editor) all references in our scenes when saving. Then check them back on upon opening that scene again.

 

We are referencing fairly simple .mb files that are duplicated as instances many times (foliage population). All we do is move/scale/rotate these instances around the scene. Seems that Maya bottlenecks with references that have around 300 instances or more, even if the model is a simple 4 triangle billboard model. We originally thought that our heavier models were causing the slowdown, but it happens with all model.mb  references with more than a couple hundred instances. However, if we reference a .mb that is just a simple locator, maya seems to handle this in a few seconds.

 

Why is it taking so long for maya to load these .mb references? Is there other instance edit information that can be removed to help speed up the process? We only need to retain the translate, rotation, and scale edits to the instance nodes.

 

Our current workaround is to replace the instances with placeholder locators, then load the reference, then re-replace the locators with fresh instances of the referece. Maya seems to be able to replace hundreds of locators with instances no problem, but drawing them immediately upon loading a reference takes much much longer. And the process of replacing back and forth is a burden on our productivity and scene organization (end up with "instance_#13000" instead of "instance_0300").

 

Any thoughts or tips on how to handle upwards of a few thousand instances would be awesome. Thanks everyone. 🙂

6 REPLIES 6
Message 2 of 7
3dMastermind
in reply to: RickFalck

Hi I conducted a quick test with 1000 instances on a somewhat subdivided primitive.

My tests were inconclusive as the referenced scene would load just as fast as the reference.

Are you sure you're not deforming the instances or adding something to the instance's complexity?

Perhaps you are adding a deformer on the referenced instances?

 

Conduct a test by reloading the reference in a fresh scene.

Move/rotate even key all the elements then save the referenced scene.

New scene...

Upon reload, does it take a long time to reload?


Manny Papamanos
StingRay | MotionBuilder | Maya | Mudbox
Games QA Specialist



Message 3 of 7
RickFalck
in reply to: 3dMastermind

Seems to be somewhat unpredictable and tricky to reproduce. We are not deforming the instances in any way. Only moving/ rotating/ scaling them around the scene. Often snapping to a 'live' terrain surface. Could this add complexity to instances?

 

I can load a reference of objectA, with 1000 instances, into an empty scene often with no problem. However when trying to load the same object with significantly less instances in a fully populated scene, sometime we encounter terrible delay. Tens of minutes in some cases.

 

Loading while in wireframe mode, and with display layers containing said instances turned off, helps with load times but still the problem persists. Anything else I should look out for?

Message 4 of 7
Calebos
in reply to: RickFalck

Hi,

 

 do you have your project structure on external disk? If yes there could be problem with network to be able to load your reference file in reasonable time. Especially windows is very awful operating system which is not able to handle huge data flow through network. You can compare it on local structure of your project with network structure if it is the case.

Message 5 of 7
RickFalck
in reply to: Calebos

No. Everything is stored locally.

 

I've had some better luck loading references/instances if I delete all of the reference edits, and then cleanup the 'groupId's (via optimize scene size). But this can be kind of time consuming in itself. I believe there is some unneccessary information being stored which is causing the slowdown. Would be better if I knew how to avoid the issue in the first place.

Message 6 of 7
rflannery
in reply to: RickFalck

There is a bug that has been fixed in Maya 2015 where scenes can get bloated with lots of hidden Node Editor objects.  That may or may not be the problem here.  You can try running this script on the referenced scene (and maybe also on the scene which references it).

 

from maya import cmds
hyperViewNodes = cmds.ls(type=['hyperGraphInfo', 'hyperLayout', 'hyperView'])
hyperViewNodes.remove('hyperGraphLayout')
hyperViewNodes.remove('hyperGraphInfo')
cmds.delete(hyperViewNodes)
print "Deleted {0} nodes.".format(len(hyperViewNodes))

 

Message 7 of 7
RickFalck
in reply to: rflannery

Thanks. I don't think this is the case (since the issue is not consistent or exclusive to any particular reference), but i will give it a shot anyway.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report