Navigation: FREDmpc (GPU raytracing and analyses) > Overview

 

Overview

 

Contact Us: fredsupport@photonengr.com

 

 

 

What is FREDMPC?


The original version of FRED performed raytracing and analysis computations on a single CPU.  As PC hardware has evolved to allow increasing numbers of processors working in parallel, new code was added to FRED to take advantage of the additional computational power and the program became "multi-threaded" (i.e. raytraces and analyses tasks are split among multiple processors working in parallel).  Not only have individual PCs become more capable with multiple processors, but networks of workstations clustered together have allowed for a distributed computing model to be implemented in FRED.  In this mode of operation, an analysis task is sent to multiple, networked PCs that can individually run their allotted work in their own multi-threaded context.  These modalities have allowed for significant decreases in computation times, but rely on expensive CPU architectures and networks that are relatively slow to evolve.

 

The newest addition to the massively parallel computing paradigm, in which a problem is broken into small chunks and operated on in parallel by multiple processors, are Graphics Processing Units (GPUs).  This GPU hardware technology, of which NVIDIA is an industry leader, allows for thousands of processing units running in parallel to be contained within a single workstation.  GPU hardware (and software) is rapidly advancing, is highly scalable, and has a relatively low entry cost when compared to distributable CPU based networks.  By simply adding, or upgrading, the GPU board in a PC, raytracing and analyses with FREDMPC can be performed orders of magnitude faster using GPUs than with conventional multi-threaded CPUs.

 

From a program structure perspective, leveraging GPUs requires that every raytrace related feature in FRED have two versions of itself in the source code base; one version written specifically for CPUs and one version written specifically for GPUs.  When a request to use the GPUs is made, the FRED model on the CPU is passed through a translator that maps each FRED feature into its equivalent GPU version.

 

The FRED model on the CPU is mapped to its equivalent code on the GPUs through a model translation step

 

 

A consequence of this structure is that every FRED feature needing support on the GPUs must be entirely rewritten in specialized GPU code.  Photon Engineering will continue to develop as much feature support for the GPUs as possible.  For a given FREDMPC version, however, not all FRED features will have GPU implementations. The Supported Features help topic provides a detailed listing of supported, partially supported, and unsupported features. 

 

Current Limitations


The following table describes, at a high level, the current major limitations of FREDMPC that can be used to quickly determine its appropriateness for a given analysis task.  For specific feature support, please refer to the Supported Features help topic.

 

Numerical Precision

The GPU raytrace and analyses can be performed with either 32-bit or 64-bit precision.

The fastest raytrace speed will be achieved in 32-bit mode, at the expense of accuracy.  For example, long propagation distances or systems with many intersections may be more susceptible to error stack-up due to single precision raytracing.  The 32-bit GPU raytrace may not be able to resolve surfaces separated by distances smaller than 1e-04 (in document units).  A comparison of the 32-bit and 64-bit GPU raytrace results can be made in order to determine whether 32-bit mode is sufficient for a given model.  Not all system models require the use of 64-bit precision raytracing.

The best accuracy will be achieved in 64-bit mode, at the expense of raytrace speed.  The performance penalty incurred with 64-bit mode is dependent on the GPU hardware itself.

Not all FRED features have exact GPU implementations.  Please refer to the Supported Features help topic for specific information regarding which features are approximated or unsupported at this time.

Coherence

FREDMPC does not support raytracing coherent rays directly on GPUs.

When coherent rays exist in the CPU ray buffer, FREDMPC does support the use of GPUs to perform analyses which require a coherent field summation (irradiance, scalar and vector wave fields, etc.).

Raytrace Paths

Raytrace path data can be tracked upon request with a user-specified maximum number of events per path.  The path data will be available in the Raytrace Paths table and the Stray Light Report.  There is currently no capability to support path-based ray selection (ex. Irradiance for rays on a specific ray path) or path redrawing.

Scripting

When a document is pushed to the GPUs, scripted surfaces, materials, coatings, etc. will be approximated.  Refer to the Supported Features help topic for specific information.

 

 

When to use FREDMPC


Assuming that the high-level program limitations described above do not prevent an analysis from being performed with FREDMPC, what other considerations should be made when deciding whether to use the GPU raytrace?

 

Model Load and Latency

Before a system can be raytraced and analyzed on the GPUs, the FRED document must be loaded into the GPU and then preparations are made in advance of raytracing.   Details of these steps can be found in the Using FREDmpc help topic, but assume, for now, that it takes 40 seconds to perform these operations (we will refer to this as the device "latency").  If the total time spent in a CPU calculation for ray creation, ray tracing, and analyses, is less than 40 seconds, then the GPUs offer no advantage over the CPUs.  As the number of rays used in the analysis is increased, the inherent speed of the GPUs for ray creation, ray tracing, and analyses, will recover from this initial latency and the GPUs will begin to outperform the CPUs.  Where the GPU raytrace will really pay dividends is when large ray counts are involved (tens of millions, hundreds of millions, or billions).

 

Analysis of Detector Distributions

If the analysis to be performed is a prediction of what a detector "would see", then FREDMPC is appropriate.  Although the capability will continue to be expanded, the current data analysis tools in FREDMPC are limited.  Path-based analysis, ray redrawing and ray filtering, for example, have limited implementations in FREDMPC and the user may need to use the CPU capabilities to extract more specific information from a raytrace.

 

Geometry Intensive Models

A notable advantage of GPUs over CPUs is that during the raytrace the GPUs excel at sorting through geometry to find ray intersections.  Consequently, if a model contains lots of geometry elements (for example, imported CAD or triangle mesh objects) then the GPUs should be considered.

 

 

Installation and Licensing


FREDMPC is not a standalone product and does not require any additional component installation beyond the normal FRED Installation procedure.  Access to the FREDMPC raytrace and analysis capability is controlled by your license authorization.  Please refer to the instruction below to check whether your license supports the use of FREDMPC .

 

After installing FRED on your PC (Installation and Setup), start the program and navigate to Help > License Authorization (or press the License Info button on the Dashboard page).  In the Software License Authorization dialog (shown below), confirm that your license authorization codes allow access to the FREDMPC capability by inspecting the "MPC" checkbox on the right hand side of the dialog.  If this option is unchecked, then your license authorization codes do not give you access to the FREDMPC capabilities.  If you have purchased the FREDMPC capability, then your license needs to be updated with its most recent license authorization passwords.  If you have not purchased the FREDMPC capability, please contact fredsales@photonengr.com to request pricing information or receive a quotation.

 

 

 

 

 

 

 

 

Copyright © Photon Engineering, LLC