odin_dust_options: Options for odin_dust

View source: R/odin_dust.R

odin_dust_optionsR Documentation

Options for odin_dust

Description

Options for controlling odin_dust; this is a superset of odin::odin_options

Usage

odin_dust_options(
  ...,
  real_type = NULL,
  rng_state_type = NULL,
  gpu = NULL,
  gpu_generate = NULL,
  compiler_options = NULL,
  optimisation_level = NULL,
  options = NULL
)

Arguments

...

Arguments passed to odin::odin_options, including verbose, workdir, no_check_unused_equations and rewrite_dims.

real_type

C++ type to use for real (floating point) numbers. Defaults to double.

rng_state_type

C++ type to use for the random number generator. Defaults to ⁠dust::random::generator<real_type>⁠ which selects a generator based on your real type. The default prior to dust 0.10.0 was ⁠dust::random::xoshiro256starstar_state⁠.

gpu

Experimental! Generate support for running models on a GPU. This implies gpu_generate but does require a gpu and nvcc toolchain. Currently not supported within package code. This argument will be passed through to dust::dust() and so to enable compilation for a gpu, pass either TRUE or the results of dust::dust_cuda_options)

gpu_generate

Experimental Generate gpu support code. This does not require a gpu or nvcc toolchain, but creates code that could be compiled for a gpu. This is primarily intended for testing and development as the generated code will be slower than the normal cpu version, and the compilation time will be considerably slower. Currently not supported within package code.

compiler_options

Additional options for the C++ compiler, passed to dust::dust

optimisation_level

Shorthand control over optimisation level, passed to dust::dust. If provided should be one of none (slow running, fast building), standard or max (enables fast math)

options

An odin::odin_options or odin_dust_options object. If given it overrides arguments; if it is already a odin_dust_options object it is returned unmodified. Otherwise it is passed through to odin::odin_options where it will override arguments in ... but respond to the odin_dust specific options (real_type, etc)

Value

A list of options (class odin_options) to pass to odin.dust::odin_dust

Examples

odin.dust::odin_dust_options()

mrc-ide/odin.dust documentation built on Oct. 10, 2024, 4:05 a.m.