Sets up an axial warping unit (AWU) for used in a deep compositional spatial model. The function
sets up sigmoids on a prescribed domain at regular intervals, with 'steepness' indicated by the user.
It returns a list of length 1 containing an axial warping unit (AWU) and several encapsulated
functions that evaluate the AWU over inputs of different types. See Value for more details.
Usage
AWU(r = 50L, dim = 1L, grad = 200, lims = c(-0.5, 0.5), dtype = "float32")
Value
AWU returns a list containing a list with the following components:
"f"
An encapsulated function that takes an input and evaluates the sigmoids over the dim-th dimension using TensorFlow
"fR"
Same as f but uses R
"fMC"
Same as f but does it in parallel for several inputs index by the first dimension of the tensor
"r"
The number of sigmoid basis functions
"trans"
The transformation applied to the weights before estimation
"fix_weights"
Flag indicating whether the weights are fixed or not (FALSE for AWUs)
"name"
Name of layer
Arguments
r
number of basis functions
dim
dimension to warp
grad
steepness of the sigmoid functions
lims
the bounded 1D domain on which to set up the sigmoids