Contents

Getting Started

Before you begin

The Accelerad programs are intended to replace the standard versions that come with the default installation of Radiance. Before you install Accelerad:

  1. Verify that you have a CUDA-enabled GPU with compute capability 5.0 to 7.5. If you are unsure what GPU you have:
    • On Windows, right click on Computer and select Properties > Device Manager > Display adapters.
    • On Linux, use the command lshw -C display to list devices.
    • On Mac, choose About this Mac from the Apple menu and go to the Displays tab.
  2. Download and install Radiance if it is not already present.
  3. Download and install the latest graphics driver for your GPU.
    • On Windows, driver version 418.81 or later is required.
    • On Linux, driver version 418.30 or later is required.
    • On Mac, no supported driver is currently available.

Confirm that Accelerad runs on your computer

To confirm that Accelerad is successfully installed on your computer, run the included Windows .bat or Unix .sh files in the demo folder. By default, this folder is located at C:\Program Files\Accelerad\demo on Windows and /usr/local/accelerad/demo on Linux.

  • Running test_accelerad_rpict should produce a high dynamic range image file named test_rpict.hdr.
  • Running test_accelerad_rtrace should produce tabular data in a file named test_rtrace.txt.
  • Running test_accelerad_rcontrib should produce tabular data in a file named test_rcontrib.txt.
  • Running test_AcceleradRT should open an interactive false color view of a simple scene (available only on Windows).

On Linux and Mac, it will first be necessary to add the Accelerad bin folder to the PATH and LD_LIBRARY_PATH environment variables. It will also be necessary and to add the Accelerad lib folder to the RAYPATH environment variable. On Windows, this will be done automatically by the installer. On Linux or Mac, add the following to the end of your ~/.profile file and edit the paths as necessary if you choose a custom install location:

export PATH=/usr/local/accelerad/bin:$PATH
export RAYPATH=/usr/local/accelerad/lib:$RAYPATH
export LD_LIBRARY_PATH=/usr/local/accelerad/bin:$LD_LIBRARY_PATH

Use Accelerad in your workflow

This suite contains Accelerad versions of several Radiance programs:

The Accelerad program ...
... replaces the Radiance program ...
accelerad_rpict rpict
accelerad_rtrace rtrace
accelerad_rcontrib rcontrib
accelerad_rfluxmtx rfluxmtx
accelerad_genBSDF genBSDF

For Windows, these programs are installed by default to C:\Program Files\Accelerad\bin. However, different Radiance tools have different expectations about where Radiance programs will be found. Depending on the tools you use, you may need to move or rename some files. You can run Accelerad in one of three ways:

Within an application: In your applications that use one of the above Radiance programs, change the paths to refer to the corresponding Accelerad program.

Replace the original programs: If your application does not allow you to edit the Radiance application names:

  1. Copy the contents of the Accelerad bin folder into your Radiance bin folder.
  2. In the Radiance bin folder, rename the Accelerad programs with the names of the corresponding Radiance programs and replace the original program files. You may want to keep backup copies of the original Radiance files elsewhere.
  3. Copy the .ptx files from the Accelerad lib folder to the Radiance lib folder.

From the command line: If you use Radiance from the command line, you can simply address your commands to the Accelerad programs instead of the corresponding Radiance programs. Be sure that the Accelerad bin and lib folder are found in your PATH and RAYPATH environment variables, respectively. On Linux and Mac, the Accelerad bin folder must also be found in the LD_LIBRARY_PATH environment variable.

Release Notes

Radiance versions

Accelerad is designed to mimic the behaviour of Radiance and has been tested in comparison with Radiance 5.2. A number of other sources exist for the Radiance executables, including DIVA, DAYSIM, and IES VE. However, these distributions may not be updated as frequently and have not been tested with Accelerad.

Missing files from RAYPATH

Accelerad locates certain files using Radiance’s RAYPATH environment variable. The message “File <filename> not found in RAYPATH” indicates that the folder containing the required file has not been added to the RAYPATH.

In Windows, this error may occur when RAYPATH has been defined in both the system and current user environment variable sets. In this case, the current user's RAYPATH will override the system RAYPATH created by the Accelerad installer. It is recommended to merge all paths from the current user’s RAYPATH into the system RAYPATH and then delete RAYPATH from the current user’s environment variables.

To edit the RAYPATH in Windows, right click on This PC > Properties > Advanced system settings > Environment Variables. The RAYPATH variable may be in either the user variables or system variables set, but should not be in both. On Linux and Mac, environment variables can be edited in the hidden ~/.profile file. Make sure that the RAYPATH variable contains paths to both the Accelerad lib and Radiance lib folders. The exact appearance will vary depending on the Radiance installations present, but a typical RAYPATH value looks like:

  • Windows
    .;C:\Program Files\Accelerad\lib;C:\Program Files\Radiance\lib
  • Linux and Mac
    .:/usr/local/accelerad/lib:/usr/local/radiance/lib

Missing library files (.dll, .so, and .dylib)

If you do not have Visual Studio 2013 installed on your Windows computer, you may see a message that “The program can’t start because MSVCR120.dll is missing from your computer.” You can download an installer for the missing file.

Linux and Mac computers may complain of missing .so or .dylib files if the Accelerad bin folder has not been added to the LD_LIBRARY_PATH environment variable. The path can be added by editing the ~/.profile file.

Graphics driver crashes

If you use a GPU that is not in Tesla Compute Cluster (TCC) mode with Windows, you may experience an unresponsive screen leading to timeout detection and recovery (TDR) while running the software. This will be accompanied by a message saying “Display driver stopped responding and has recovered” similar to the one below.

TDR error message

By default, the Windows OS will end processes on the GPU (essentially rebooting it) after two seconds of unresponsiveness, which can happen when the GPU is processing a large amount of data. Possible remedies include:

  • If more than one graphics card is available, set CUDA_VISIBLE_DEVICES to use only the GPUs that are not connected to monitors.
  • Increase the TDR delay by adding a registry key and restarting your computer. This is not recommended for novices.
  • Test on a more powerful graphics card or a card which is not connected to a monitor. Tesla cards or other cards with TCC mode enabled are not affected by TDR.

Supported GPUs

Accelerad is targeted toward newer graphics hardware with RTX capability. It is compatible with graphics hardware with CUDA compute capability 5.0 or greater ("Turing", "Volta", "Pascal", or "Maxwell"). As of version 0.7 beta, older hardware ("Kepler" and "Fermi") is no longer supported.

If you receive an error stating "A supported NVIDIA GPU could not be found" even though your machine has a supported GPU, you must update to the latest graphics driver.

Disabling GPU acceleration

You can reproduce the normal behavior of Radiance on the CPU in Accelerad by providing the argument -g- to most Accelerad programs. When this argument is given, Accelerad will not use the GPU for any calculations, and normal Radiance algorithms will be used.

AcceleradRT requires use of the GPU and does not support -g-.

Slow first run

In order to achieve high speeds, Accelerad compiles certain GPU code specifically for the GPUs available on your computer and caches it for later use. This may result in longer startup times the first time Accelerad is run or a new model is created. On subsequent runs, the cached programs are used, resulting in a much shorter startup time.

Distance to origin

Because ray intersection calculations on the GPU use single-precision floating point arithmetic, some imprecision is likely for geometry that is located far from the origin. In particular, this can lead to stack overflow errors, which appear as warning messages. Additionally, warnings will appear as red pixels in accelerad_rpict. Accelerad makes an effort to avoid these issues, but the result is that surfaces far from the origin may appear incorrectly. As a solution, scale the model in meters and position the model so that relevant geometry is less than 100 meters from the origin.

Unexpected high and low values

Accelerad flags computation errors with brightly-colored results. If you see results with much higher radiance values than expected, check the command-line output for error warnings.

Low or patchy radiance results may indicate insufficient ambient coverage. You may correct this by varying the ambient parameters, including the additional Accelerad command line arguments.

Patchy or blotchy rendering

Patchy or blotchy rendering may occur if the irradiance cache provides insufficient coverage of the scene. This algorithm may occasionally to undersample diffuse lighting in many-bounce paths. The size of the irradiance cache in accelerad_rtrace or accelerad_rpict is fixed by the -ac parameter. To increase ambient coverage, increase the -ac or -aa parameter value, or decrease the -ar argument. To turn off irradiance caching, set the ambient accuracy -aa to zero.

Irradiance caching is not used in accelerad_rcontrib or AcceleradRT.

BSDF Use

Accelerad includes accelerad_rcontrib, which can be used to create bidirectional scattering distribution functions (BSDFs) by rtfluxmtx or genBSDF. However, the current Accelerad version does not take BSDF files as input. Three-phase method simulations using Accelerad produce accurate results because this simulation type does not cast rays through the BSDF material. However, five-phase method simulations may produce lower illuminance results in Accelerad because interreflection of the direct solar component within the BSDF material is not taken into account.

Antimatter

Accelerad allows the use of up to 32 antimatter materials. However, the use of antimatter can lead to slow-downs in rendering, reduce the number of ray reflections that occur, or cause trace depth exceeded errors. Low ambient lighting values may result inside antimatter volumes. It is recommended to model holes in surfaces explicitly rather than use antimatter in models.

Command Line Arguments

In addition to the command line arguments typically used by rpict, rtrace, and rcontrib, Accelerad introduces optional new command line arguments required for the GPU implementation of certain algorithms. These new parameters are summarized below:

ArgumentDescription
Default Value
-g Enable or disable GPU ray tracing. A value of -g- will cause the Accelerad programs to revert to normal Radiance behavior without using the GPU.
-g+
-gv level Set the verbosity of GPU debugging to level. Level 0 produces the fastest output but will not display GPU errors which could affect results. Level 1 reports GPU errors. Levels 2 and 3 provide additional GPU stats but result in longer computations.
0
-al stride Set the spacing between seed point pixels for ambient sampling to stride in rpict only. A value of zero will cause all pixels to be considered. This option is ignored when the -az option is used.
0
-ag N Set number of ambient divisions for final gather infill to N. When -aa is non-zero, N ambient samples will be taken at points not covered by the precomputed irradiance cache. A value of -1 will cause the value to be copied from -ad.
-1
-az res Set the number of seeds points for ambient samples to take around the circumference of a sphere based at the view point to res in rpict only. A value of zero will cause view-dependent seeding to be used instead. Thus, zero should not be used in combination with the -S option in which a view file changes the view direction from between frames.
0
-ac N Set the number of k-means clusters for ambient calculation to N.
4096
-an N Set the maximum number of k-means iterations to N. Larger values can cause k-means calculation to take longer but will generate more accurate ambient results.
100
-at thresh Set the k-means threshold to thresh. This is the fraction of seeds that must change cluster in order for k-means iteration to continue. Smaller values can cause k-means calculation to take longer but will generate more accurate ambient results.
0.05
-ax wt Set the weighting factor for position in k-means error calculation to wt. Small values concentrate more ambient calculations around edges where ambient gradients are likely to be large.
1.0

Current Limitations

The purpose of this project is to demonstrate the feasibility of performing Radiance-style simulations on the GPU by implementing a variety of commonly-used simulation and material parameters. This section lists the status of Radiance parameters and objects in Accelerad according to the following key:

  • Implemented
  • Partially Implemented
  • Not yet Implemented
  • Unnecessary

The table below lists currently supported parameters. Unsupported parameters will be ignored. Hover over a parameter for details.

  • -aa
  • -ab
  • -ad
  • -ae
  • -aE
  • -af
  • -ai
  • -aI
  • -am
  • -ap
  • -ar
  • -as
  • -av
  • -aw
  • -b
  • -bn
  • -bv
  • -c
  • -dc
  • -dj
  • -dp
  • -dr
  • -ds
  • -dt
  • -dv
  • -e
  • -f
  • -h
  • -i
  • -I
  • -ld
  • -lr
  • -lw
  • -m
  • -M
  • -ma
  • -me
  • -mg
  • -ms
  • -n
  • -o
  • -pa
  • -pd
  • -pj
  • -pm
  • -ps
  • -pt
  • -r
  • -ro
  • -S
  • -ss
  • -st
  • -t
  • -u
  • -V
  • -va
  • -vd
  • -vf
  • -vh
  • -vl
  • -vo
  • -vp
  • -vs
  • -vt
  • -vu
  • -vv
  • -w
  • -x
  • -y
  • -z

The status of each of the Radiance object types are listed below. Unsupported surface types, textures, and patterns will be ignored. Surfaces assigned unsupported materials will also be ignored. Hover over a type for details.

  • aBSDF
  • alias
  • antimatter
  • brightdata
  • brightfunc
  • brighttext
  • BRTDfunc
  • BSDF
  • bubble
  • colordata
  • colorfunc
  • colorpict
  • colortext
  • cone
  • cup
  • cylinder
  • dielectric
  • glass
  • glow
  • illum
  • instance
  • interface
  • light
  • mesh
  • metal
  • metal2
  • metdata
  • metfunc
  • mirror
  • mist
  • mixdata
  • mixfunc
  • mixpict
  • mixtext
  • plasdata
  • plasfunc
  • plastic
  • plastic2
  • polygon
  • prism1
  • prism2
  • ring
  • source
  • sphere
  • spotlight
  • texdata
  • texfunc
  • trans
  • trans2
  • transdata
  • transfunc
  • tube