News:

Please note new Forum URL: forum.designcad.com

Main Menu
DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

Large file information

Started by Dr PR, August 12, 2014, 03:03:24 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Dr PR

Recently I have been working on a pretty large file - 284 Mbytes - in V23.1 (RedSDK disabled). This is pretty close to the limits of what you can do in DesignCAD. Here are some "statistics" about program performance with large files.

The file has 854,796 entities total, with 6,375,358 points, 461,464 grid surface entities and 392,965 planes. I think it has taken me 5-6 years to draw all of that stuff.

File loads take 44 seconds (wireframe view). File saves take about 2 minutes 15 seconds, primarily while the group IDs and solid IDs are being packed.

When I first rendered it with Gouraud (graphics acceleration enabled) it took 61 minutes to produce the first image on the screen.  DesignCAD has to calculate all of the surface normals (about 850,000), colors, shadow masks, etc. before an image can be produced. After that it takes about 11 seconds to generate each new Gouraud image.

Note: There is no "Glass" material in the drawing and transparency was disabled.

It takes about 14 seconds to redraw the wireframe image (only one window, the main window).

I saved a bunch of images with "File/Image/Save Image File" using Smooth Shading and a resolution of 3753 x 2048 pixels. Each image took 59 seconds to generate. I tried saving an image that was 5630 x 3072 pixels but I got a message saying there wasn't enough memory to shade the image, so it is pretty close to DesignCAD's memory limit. This is the 32 bit DesignCAD memory limit - the computer has about 28 gigabytes of free RAM.

Here is an image reduced to 1024 x 559 pixels.

Phil
DesignCAD user since 1987

Rob S

#1

Looks like it's a bit low in the water!!!    ( I know, it's only the superstructure)

For those who might not know, in addition to the gazillion gigaytes of ram, you might post here the specs for the rest of your super-computer, which I have seen in the Beta forum.

I think the times would be much greater on a "normal" machine, but theoretically it should still work. 
User since forever

Dr PR

Rob,

It really isn't a "supercomputer." There are a lot faster machines out there. I just made some careful selections for the parts when I assembled the machine in January of 2013.

Intel i7-3930K CPU at 3.2 GHz
Intel DX79SR motherboard
32 GBytes DDR3 1600 synchronous RAM
Three 1 Tbyte SATA hard drives
Nvidia Quadro 2000 video card
Tower case with eight fans (four blowing in over the hard drives and video card, two exhaust on the top and two exhaust on the liquid cooler radiator.
Win 7 Pro 64

The CPU can be overclocked, but I haven't done that. It does have the Intel "Turbo Boost" that allows it to speed up to 3.7 GHz as long as the CPU doesn't overheat. It has thermal protection built in so it can't self destruct. I have a liquid cooler on it to dissipate heat, but it rarely gets warm enough for the fans to speed up. The CPU has 6 cores and can run 12 threads, but as far as I can tell DesignCAD uses only one core and one thread. The 64 bit CPU and memory run much faster than 32 bit systems.

The motherboard BIOS supports Intels XMP protocol that allows matching the system memory bus to the RAM specifications. I chose Corsair RAM modules that would run at 1600 MHz at the nominal bus voltage of 1.5V. They also had relatively short RAS and CAS timing - fast memory access. At the time these were the only RAMs that would do this. This is the key to high speed  operation.

Four 8 Gbyte RAM modules are interleaved so that during sequential memory read/write operations each is accessed sequentially - each RAM sees only a 25% duty cycle. This allows the system to run much faster than if it was always reading out of one RAM module.

I have disabled the useless Aero interface in Win 7 along with all the other eye candy bulls**t, and have selected the "Classic" Windows interface. Indexing is disabled.

The machine has no network connections - I use another machine for Internet browsing and email. This means that there are no background network operations to steal CPU cycles.

I chose the Nvidia Quadro 2000 video card because it is supported by the RedSDK software that is being incorporated into DesignCAD. This should allow me to test more of the features of the RedSDk package. Interestingly, although the card is optimized for OpenGL, some tests posted on the Internet show it is one of the faster gaming cards using Direct X.

****

In timing tests this machine is 2-5 times faster than other machines posted on this forum. For comparison, running DesignCAD my i7 machine is 12 times faster than my single core 3 GHz P4 XP Pro 32 bit machine. The i7 machine is 3-4 times faster than my dual core 2.4 GHz 64 bit Intel E6600 Core2-Duo Vista Home Premium 64 machine.

Phil
DesignCAD user since 1987

prl

Quote from: Dr PR on August 12, 2014, 03:03:24 PM
I think it has taken me 5-6 years to draw all of that stuff.

Amazing work and great stats on DesignCAD and their operators!   It appears you are the slowest part of your super project.  You need a Multi-Core Phil chip.

samdavo

#4
Can I play Devil's Advocate and suggest that for such large projects there are probably more efficient programs than DCAD ?  eg Solidworks , even if it costs over 70 times as much (?)

PS For small jobs I would use DCAD 10 times out of 10.   But for this? wow!

>"61 minutes to produce the first image on the screen."

Phil,
The other thing that needs to be mentioned surely is that you are using a thousand tricks that you have learnt over 30 years of using DCAD!  And without those tricks, it would be twice as slow to "produce images" as you currently endure.  You are probably the best-qualified person in the world to do that drawing in DCAD (probably no argument) - but gee,  61 minutes !! 

Dr PR

Well, there have been a lot of distractions since I started the whole project 10 years ago. Business got in the way for a while, but I am retired now. Lately it has been my lady who has been leading me astray. We travel a lot, and when we are home we do a lot of hiking. So the ship project only gets part of my spare time. But, so what? I'm not in a hurry, and I am patiently waiting for the RedSDK display improvements and a 64-bit version of DesignCAD to come along.

****

The 60 minute renders really aren't a problem. I start the program and start the rendering before I begin meal preparation or while I am doing housework. Then when I am finished the drawing is rendered. After that it takes only 11 seconds to generate another rendered image after rotating the view or zooming. And if I add new (small) objects to the drawing they don't increase the render time appreciably.

About 20 years ago I wrote a hiking book for my home town. I used a different modeling program to create 3D mesh images of topography (similar to DesignCAD's grids). One of those images took 45 minutes to redraw every time I zoomed or rotated the image! It took weeks to draw that one single map!

Before that, in the 1970s on my first scratch-built 4 MHz Z-80 machine I had a database that took 6 days to recalculate! Assuming, of course, that the power company could keep the electricity on for six days straight.

So the initial 60 minute delay really isn't much of an inconvenience compared to what I remember from the "bad old days."

****

Over the years I developed a lot of tricks to minimize file size and rendering times. However, I'm not sure that some of those tricks help that much, and some may actually make things worse. So now I stick to plain-vanilla DesignCAD drawing techniques and wait for faster computers to make the difference.

If/when we do get a 64 bit version of DesignCAD the code should execute significantly faster, and we should be able to create much larger drawings. However, initialization for the RedSDK files may take much longer than the current program, and rendering with ray tracing may take a very long time.

Again, so what? For really high quality images - which I need only after a project is completed - I can start the rendering before going to bed.

Phil
DesignCAD user since 1987

samdavo

#6
Phil
Fair enough.

Hell
It sounds like, if I start a similarly large project, I will have to learn to cook :)

PS There are things in DCAD I prefer over Solidworks.  The simplicity of only having one file (or for this size I suppose you could have a few sections of the ship in their own "simple" files and bring them together at the end.  If you use the library in Solidworks to bring in say a bolt, then you (usually) have to make sure you include that symbol when you put the package together for the drawing when completed.  Likewise the drawings that are generated are in files of their own - that cammon stand alone without the file of the parts and/or the assemblies.   Painful.   I like importing a symbol in DCAD, and just save everything you can see (or have hidden) in one simple easy file (2 cents) - including the output drawing(s).  But like I have also said, my drawings are pretty simple.

Dr PR

Sam,

Because of the file size limitations I have constructed the ship in several different files. Eventually I hope to be able to put them together in DesignCAD. If not, I will change to a program that can work with gigabyte files.

One curious thing I have discovered about DesignCAD is that you can build files of about 330-350 Mbytes by copying and pasting multiple large drawings into a blank drawing. This works so long as you 1) do not edit the file, and 2) do not render it.

Editing causes a backup copy to be created in RAM, and there isn't enough memory space to backup a 350 Mbyte file - the program crashes.

Rendering causes the program to use memory space for the image, and this reduces the memory space for the file.

So I have put together 300+ Mbyte files using cut/paste to bring together large pieces, and after all parts are in place I have rendered them with "File/Image/Save Image File." After the image is rendered you can no longer make changes to the file. In some cases I haven't even been able to save the large file.

Phil
DesignCAD user since 1987

Rob S

Wow, now that is really pushing the limits.

How many engineering students can you fit into (more or less) a Volkswagen again....

And if Sam learns to cook, who knows what may happen!!!
User since forever

Bob P

Dr PR,

Are you actually adding the basic drawings together or are you inserting them as "symbols"?  Is there any substantive difference in the way the total drawing acts with one technique or the other?

prl

#10
Quote from: Bob P on August 14, 2014, 02:20:09 AM
Are you actually adding the basic drawings together or are you inserting them as "symbols"?

Same thoughts, specifically the external referenced symbol(s) concept.  Your "total master" drawing is simply an empty shell drawing with positioning references in 3d space for your component assembly drawings (which you work separately).

I once partially worked out a scheme that let me do this concept where in the master drawing I would select the xref and would run a macro to load that xref as a separate drawing.  Work the separate drawing, save it and simply reload the master drawing.  Nothing ever gets worked in the master drawing.

Lar

#11
Symbols only makes the host file's size smaller. Once you open the host file then all the parts still have to be loaded into RAM... and each symbols itself may require a bit more RAM.

One trick for saving images would be to temporarily get rid of things that would not be seen at the viewing angle of the image. First open the component file that has the front most entities of your intended view, save-as, then rotate the view to the viewing angle. Now delete unseen things, or slice away the backs of things, keeping in mind what shadows should be seen in the final image. Also don't slice things that would end up creating more points that the original. Then merge the next front-most component file (each file should have drawing handles {not selection handles} set at 000 so when merging you don't have to worry about snapping to things that you got rid of) and get rid of its unseen stuff. Do this for a few components then save the file, close and reopen to clear the 'undo-ram'. Repeat this process until all the parts are done and you should now have a much smaller file that depicts the full model from your viewing angle. Its lots of work and its only good for one viewing angle but at least you get a full image.

Another trick is to save images of each component (or compile a few) from the same viewing angle and window size (you can save and load screen configurations via the file menu) then compile the images in an image processor. You will have to be careful of shadows again.

Now that Phil was kind enough to provide this information on large files, if I was to take on such a project (and dcad is not yet 64 bit) I would create less detailed duplicate components and use them for when they are far away from the camera. Or, for things like curved hulls with windows that you don't see through, I would make the window separate from the hull so it not only reduces points but I can temporarily get rid the windows that are not seen when saving an image. Things like rope that are far away can be represented by a vector rather that a 3d construction.

Lar

prl

Quote from: Lar on August 14, 2014, 06:43:58 AM
Symbols only makes the host file's size smaller. Once you open the host file then all the parts still have to be loaded into RAM... and each symbols itself may require a bit more RAM.

Depending on how one organizes all the subset components, more specifically, how one names them, it is possible to have a routine that loads all xref symbols in the master drawing that have the prefix/suffix  say _Ext_.  That would load a master drawing where the intention is to view it from the outside only.  In other words, all interior missile parts or ship's boiler room components etc. would not be loaded.   Call it components management, especially in something as complex as what Phil is putting together.




Dr PR

My ship model is constructed in "small" pieces - winches, boats, smoke pipes, king posts, turret, missile launcher, radar towers,  antennas, etc. These parts can be 5 to 50 Mbytes. They are highly detailed models in their own right. Someday I hope to make walkthrough videos and these small details will be necessary to add realism to the images.

Then a bunch of these pieces are copied into a larger "subassembly" drawing, like the forward, midships and after superstructures. First the base deckhouse structure is created and then the pieces are added. The basic no frills deckhouse structure is typically about 10-15 Mbytes. With the details added the subassembly drawing can be up to 280 Mbytes.

I eventually expect to have four subassemblies:

Hull (mostly complete)
Forward superstructure
Midships superstructure (almost complete)
Aft superstructure (almost complete)

Someday I hope to be able to combine all four into one drawing so I can generate whole ship images.

****

I thought about cutting away "unseen" parts, but this would be a huge amount of work, and a major distraction from the main job of just drawing all of the parts and subassemblies. A major problem with this is that some of the elements outside the picture may cast shadows in the picture area.

****

Another thought was to eliminate all the small parts like screws, nuts, bolts, washers, rivets, etc., to make the files smaller. I actually did this with the AN/SPG-49 missile tracking radar antenna. It is the largest single piece - 45 Mbytes. After eliminating all the fasteners the file size as about 30 Mbytes. So 1/3 of this complex assembly is fasteners! And there are two of them on the after superstructure, so this would reduce the file size by 30 Mbytes.

However, most drawings don't have that many fasteners, so all that work really wouldn't produce much reduction in file size. Since I am currently limited to less than 300 Mbytes total, and the subassemblies are already about 727 Mbytes, I would have to reduce file sizes by about 60%, and that won't happen.

****

To reduce file sizes I have meticulously used minimum facet counts. DesignCAD does a good job of rendering cylinders with 36 facets, especially where two cylinders are joined with "Solid Add." For larger cylinders like the radar tower struts I used 36 facets. Really large cylinders, like the base for the gun director, need 72 facets to render properly.

But small details like bolts don't need more than 12 facets - just don't look too closely.

Some cylindrical items really shouldn't have smooth surfaces - like ropes and cables. But there is no way I am going to model ropes with all the separate helical strands - one short rope could be 100 Mbytes! Instead, I use 8-sided polugons ("Circle" with plane and 8 factes selected). I extrude the polygon along the necessary curve, using the absolute minimum number of intermediate breaks. When rendered these 8-sided solids look really crummy up close, but from a short distance the surface is "confused" enough to pass for a rope or cable. Cheap trick, but it works.

****

Another trick is to not use "Solid Add" to combine two cylinders. Instead draw the first cylinder, then duplicate it in place (N). Then draw the second intersecting cylinder. Now use "Solid Subtract" to subtract the duplicate of the first cylinder from the second. This has two effects:

1. The resulting number of facets MAY be smaller because the first cylinder remains a simple cylinder. Only the second cylinder is modified.

2. You can use cylinders with fewer facets - say 24 or 16 - instead of 36. If you add cylinders whith a small number of facets the resulting distorted cylinders render poorly, with the edges of the facets showing near where the cylinders come together.

But if you use the duplicate subtraction method only one cylinder is distorted. This is especially useful if you are joining a smaller diameter cylinder to a larger one. Cut the smaller one because the facets won't be as visible.

I have even exploded the cut cylinder, deleted the hidden facets, then regrouped the parts into a solid (Solid Define), but I'm not sure this actually reduces file size. Someday I need to run a test to see.

****

For cables that will never be viewed closely, like antenna wires, just extrude a "+" shape. This will produce the minimum number of facets necessary to render looking like a small diameter cylinder, and it will cast a shadow (simple lines don't cast shadows).

****

I have been looking for ways to cut corners and reduce file size for a decade now. And the thing is still 720 Mbytes and growing!

****

I have thought of rendering each subassembly separately and then combining them in Photoshop. I may try this after the drawings are complete. I'll probably have to fake some shadows that would be cast from one subassembly on another, but from a distance they should look OK.

****

Although I am working on a ship model these ideas can be applied to other large models like shopping malls, large apartment complexes, city models, etc.

Phil
DesignCAD user since 1987

samdavo

Quote from: Rob S on August 13, 2014, 06:32:37 PM
if Sam learns to cook, who knows what may happen!!!
Rob,
I clicked "render this massive canoe" , and got up to try a 90-second porridge sachel.
But before I had taken a step  (or blink for that matter), it was finished already.  :)
Once again my cooking lesson was foiled.   !