Dan Bayn wrote:
Some background information first:
We import STEP files created in Solidworks, and it is important that the object name used in Solidworks comes through to Rhino. In V4, you could explode the nested block instances, and the object name would stick. In V5 that doesn't happen anymore. I've posted about this for years, but it doesn't look like anyone is going to change it anytime soon. So I wrote a script in Rhinoscript that took the block instance name and applied it to the exploded block instance, so that the polysurface would be named correctly. Works well.
Fast forward to 2014, and I have re-written this script in Python. Now, if I import what I consider a medium size STEP file (say 50Mb) using Python, Rhino hangs for 4 or 5 minutes. When it finally wakes up, the operation is completed successfully. Try it with an 80Mb STEP file and it hangs for over 10 minutes. It appears to have locked up, but if you wait long enough it succeeds.
Here is what has me stumped. If I import a STEP file using Rhino's traditional import command, then run a "stand-alone" version of the script, it doesn't hang. If I go back and import the file using Python, which includes the exact same code as the "stand-alone" version, it hangs again.
I can't post the STEP file publicly, but if anyone at McNeel is interested in testing this, I can supply the scripts and the STEP file for analysis.
Thanks,
Dan
Posts: 1
Participants: 1