Chapter 3. Working with Files

Table of Contents

Creating a New PyroSim Model
Saving a PyroSim Model
Open a Saved PyroSim Model
Importing FDS Models
Exporting FDS Models
Import DXF Files
Convert Solid Geometry
DXF Import Dialog

Several files are used when performing a fire analysis using PyroSim. These include the PyroSim model file, the FDS input file, and FDS output files. This section describes how to load and save files in the formats supported by PyroSim.

Creating a New PyroSim Model

When PyroSim is started, it begins with an empty model. You can close the current model and create a new empty model by opening the File menu and clicking New. PyroSim always has one (and only one) active model.

Saving a PyroSim Model

The PyroSim model file (.psm) is stored in a binary format that represents a PyroSim model. The PyroSim model contains all the information needed to write an FDS input file, as well as additional information such as obstruction grouping, floor heights, background images, and textures. This format is ideal for sharing your models with other PyroSim users.

To save a new model:

  1. On the File menu, click Save.

  2. Enter the file name and click the Save button.

Open a Saved PyroSim Model

PyroSim model files have a .psm extension. To open a saved model:

  1. On the File menu, click Open....

  2. Select the file and click the Open button.

A list of recently opened files is also available. To open recent files, on the File menu, click Recent PyroSim Files, then click the desired file.

PyroSim has an auto-save feature which stores a copy of your current model every 10 minutes. This file is automatically deleted if PyroSim exits normally, but if PyroSim crashes, you can recover your work by opening the autosave file. It can be found either in the same directory as your most recent .psm file, or in the PyroSim installation directory if your model was unsaved.

For more information about opening files saved with previous versions of PyroSim, please refer to Appendix A.

Importing FDS Models

PyroSim allows you to import existing FDS input files. When you import an FDS file, PyroSim will create a new PyroSim model from the imported file. During import, PyroSim will check for the validity of each record. If errors are detected, you will be notified. You may then make the required corrections and attempt to import the file again.

To import existing FDS models into PyroSim:

  1. On the File menu, click Import, then click FDS File....

  2. Select the FDS file and click Open.

PyroSim supports file import for versions 4 and 5 of FDS. For more information about opening files compatible with version 4 of FDS, please refer to Appendix A.

Exporting FDS Models

PyroSim also allows you to explicitly export the current model to an FDS input file. You can manually edit the file to take advantage of advanced FDS features, or to easily transfer the input file to a different machine or special version of FDS.

To export an FDS file:

  1. On the File menu, click Export, then click FDS File....

  2. Enter the file name and click Save.

The file exported by PyroSim will be compatible with version 5 of FDS.

Import DXF Files

To import DXF geometry into your PyroSim model, you can use the Import DXF dialog.

  1. On the File menu, click Import, then click Import DXF....

  2. Select a DXF or zipped DXF file to import.

  3. Specify units, layers, and other settings.

  4. Click OK.

Convert Solid Geometry

PyroSim will only generate FDS geometry for lines, polylines, and faces. Other entities present in the DXF file will be ignored. In particular, any 3D solid geometry in a DXF input file will not be imported. To transfer a 3D solid AutoCAD model into PyroSim, you must first decompose the solid entities into 3D faces. You can do this using the explode command in AutoCAD.

Some solid AutoCAD geometry cannot be readily decomposed with the explode command. In this case, you can use the following procedure to decompose the solid object into faces.

  1. Select the objects you wish to export to PyroSim. The ALL command will select everything.

  2. Export the selected objects to the 3D studio file format with the 3DSOUT command

  3. In the 3D Studio File Export Options dialog, select the following options:

    • For Derive 3D Studio Objects From, select AutoCAD Object Type

    • For Smoothing, select Auto-Smoothing and 30 degrees

    Then click OK to export the objects

  4. Open a new drawing, then import the objects using the 3DSIN command

  5. The objects will be imported as polyface meshes. Use the explode command on the meshes to create 3D faces.

  6. Save this new drawing as a DXF file

DXF Import Dialog

The following sections describe the major elements of the Import DXF dialog.

Layers

If your DXF input file has been organized into layers, you can control which layers are imported using the list on the left hand side of the Import DXF dialog. All of the layers in the file will be initially selected, but you can instruct PyroSim to ignore particular layers by deselecting them in the list. As you select and deselect layers, the 3D preview window will display the items that will be imported. Deselecting a layer will have no effect on the imported background image.

Length Unit

PyroSim will scale and orient the obstructions and background image generated from your DXF file based on your selection of a length unit. It is very important that you specify the length unit because this information cannot be inferred from the DXF file and it will control the location and size of all imported geometry.

To specify the length unit:

  1. In the Import DXF dialog, click the Units list.

  2. Click the unit of length used in your DXF file.

The 3D preview window will be automatically updated to reflect the selected length unit.

Settings

The DXF Import Preferences dialog allows you to control what information PyroSim will extract from the DXF file. To access this dialog, click the Settings... button in the Import DXF dialog.

The General tab provides the following options:

  • Import Colors Select this option to apply the color of an imported DXF entity to the corresponding PyroSim geometry object(s).

  • Import Empty Layers Select this option to create groups in PyroSim for layers that don't contain any importable entities.

  • Import Background Image Select this option to create a 2D image of the imported DXF file and add this image to the current model as a Floor. The position and visibility of the background image can be edited later using the Configure Background Image dialog.

  • Default Wall Width Edit this value to control the width of walls generated from 2D DXF entities.

  • Default Wall Height Edit this value to control the height of walls generated from 2D DXF entities.

The length unit used to control wall width and height will be the same as specified in the Import DXF dialog. Note that this is not necessarily the same unit as your PyroSim model. PyroSim will automatically convert from the DXF unit to the model length unit.

The Entities tab provides the following options:

  • Import LINEs Select this option to convert LINE entities in your DXF file to wall objects in your PyroSim model. The height and width of the imported walls is set by the corresponding entries in the General tab.

  • Import LWPOLYLINEs Select this option to convert LWPOLYLINE entities in your DXF file to wall objects in your PyroSim model. The height and width of the imported walls is set by the corresponding entries in the General tab.

  • Import 3DFACEs (Beta) Select this option to convert 3DFACE entities in your DXF file to convex polygon objects in your PyroSim model. Models with many faces require a large amount of memory. If you reach the memory limit, you can break the AutoCAD model into parts. These parts can then be separately imported and merged in PyroSim.

Using these options, PyroSim will create 3D solid geometry suitable for use with FDS from the entities defined in your DXF file. Once these entities have been imported, you can use PyroSim to edit the resulting objects.