Let me try to explain what is needed.
The code in RandomDistributedScalarEncoder.cpp shows that the internal parameters used by the algorithm are computed from three parameters. These are the size
, and one of activeBits
or sparsity
but not both, AND only one of: radius
, resolution
or category
. It will issue an error if you don’t follow this rule.
If you don’t happen to use resolution
as one of the parameters, the program will compute the resolution from the parameters that were given, i.e. radius
/ activeBits
. And activeBits
could be computed from size and sparsity
if sparsity
is given. So the computed resolution could be a fraction.
This allows the encoder to be configured using multiple ways depending on how you think of the data.